Adjust CKAN Dockerfile - move common deps, cleanup properly
This commit is contained in:
parent
7cdd22261e
commit
8ff4cfe525
@ -3,14 +3,16 @@ MAINTAINER Disassembler <disassembler@dasm.cz>
|
|||||||
|
|
||||||
RUN apk --no-cache add python2
|
RUN apk --no-cache add python2
|
||||||
|
|
||||||
RUN apk --no-cache add libjpeg-turbo libmagic libpq libxml2 libxslt py2-pip zlib \
|
RUN apk --no-cache add libxml2 libxslt
|
||||||
|
|
||||||
|
RUN apk --no-cache add libjpeg-turbo libmagic libpq py2-pip zlib \
|
||||||
&& apk --no-cache add --virtual .deps git build-base libjpeg-turbo-dev libxml2-dev libxslt-dev postgresql-dev python2-dev zlib-dev \
|
&& apk --no-cache add --virtual .deps git build-base libjpeg-turbo-dev libxml2-dev libxslt-dev postgresql-dev python2-dev zlib-dev \
|
||||||
&& echo 'http://repository.fit.cvut.cz/mirrors/alpine/edge/testing' >>/etc/apk/repositories \
|
&& echo 'http://repository.fit.cvut.cz/mirrors/alpine/edge/testing' >>/etc/apk/repositories \
|
||||||
&& apk --no-cache add geos \
|
&& apk --no-cache add geos \
|
||||||
&& ln -s /lib/ld-musl-x86_64.so.1 /lib/libc.so.1 \
|
&& ln -s /lib/ld-musl-x86_64.so.1 /lib/libc.so.1 \
|
||||||
&& mkdir -p /srv/ckan \
|
&& mkdir -p /srv/ckan \
|
||||||
&& cd /srv/ckan \
|
&& cd /srv/ckan \
|
||||||
&& pip install setuptools==36.1 \
|
&& pip install -U setuptools \
|
||||||
&& pip install -e 'git+https://github.com/ckan/ckan.git#egg=ckan' \
|
&& pip install -e 'git+https://github.com/ckan/ckan.git#egg=ckan' \
|
||||||
&& sed -i 's/psycopg2==2.4.5/psycopg2==2.7.1/' /srv/ckan/src/ckan/requirements.txt \
|
&& sed -i 's/psycopg2==2.4.5/psycopg2==2.7.1/' /srv/ckan/src/ckan/requirements.txt \
|
||||||
&& pip install -r /srv/ckan/src/ckan/requirements.txt \
|
&& pip install -r /srv/ckan/src/ckan/requirements.txt \
|
||||||
@ -29,7 +31,8 @@ RUN apk --no-cache add libjpeg-turbo libmagic libpq libxml2 libxslt py2-pip zlib
|
|||||||
&& chown -R ckan:ckan /srv/ckan \
|
&& chown -R ckan:ckan /srv/ckan \
|
||||||
&& apk del .deps \
|
&& apk del .deps \
|
||||||
&& find /srv/ckan/src -name '.git*' -exec rm -rf {} + \
|
&& find /srv/ckan/src -name '.git*' -exec rm -rf {} + \
|
||||||
&& rm -rf /root/* || true
|
&& rm -rf /root \
|
||||||
|
&& mkdir /root
|
||||||
|
|
||||||
VOLUME ["/etc/ckan", "/srv/ckan/storage"]
|
VOLUME ["/etc/ckan", "/srv/ckan/storage"]
|
||||||
EXPOSE 8003
|
EXPOSE 8003
|
||||||
|
Loading…
Reference in New Issue
Block a user