almost there - dockerizing
This commit is contained in:
15
Dockerfile
15
Dockerfile
@@ -1,16 +1,7 @@
|
||||
FROM debian
|
||||
RUN mkdir /srv/app
|
||||
RUN mkdir /srv/venv
|
||||
RUN apt-get update
|
||||
RUN apt-get install -y default-libmysqlclient-dev gcc
|
||||
RUN apt-get install -y postgresql postgresql-contrib libpq-dev python-psycopg2
|
||||
RUN apt-get update && apt-get install \
|
||||
-y --no-install-recommends python3 python3-virtualenv python3-dev
|
||||
RUN apt-get update && apt-get install libssl-dev
|
||||
RUN python3 -m virtualenv --python=/srv/venv/
|
||||
FROM rosti/python:3.6
|
||||
COPY ./requirements.txt /srv/app/
|
||||
WORKDIR /srv/app/
|
||||
RUN . /srv/venv/bin/activate && pip install -r requirements.txt
|
||||
ENV VIRTUAL_ENV = /srv/venv
|
||||
RUN /opt/python/bin/pip install -r /srv/app/requirements.txt
|
||||
COPY . .
|
||||
EXPOSE 8000
|
||||
CMD ["init.sh"]
|
||||
|
||||
Reference in New Issue
Block a user