del not needed

prod
Dmitriy Shesterkin 9 years ago
parent 97c62b533b
commit 62e0b73d88
  1. 65
      Dockerfile.debian
  2. 4
      conf/docker/entrypoint_stage.sh

@ -1,65 +0,0 @@
FROM python:3.6
ENV PYTHONUNBUFFERED 1
ENV NGINX_VERSION="1.13.2" \
NGINX_OPTS="--with-http_ssl_module \
--with-http_gzip_static_module \
--prefix=/usr/share/nginx \
--sbin-path=/usr/sbin/nginx \
--conf-path=/etc/nginx/nginx.conf \
--pid-path=/var/run/nginx.pid \
--http-log-path=/var/log/nginx/access.log \
--error-log-path=/var/log/nginx/error.log \
--user=www-data \
--group=www-data \
--add-module=/tmp/modules/nginx_requestid-master"
COPY requirements /opt/app/requirements
RUN apt-get update -y && \
apt-get upgrade -y && \
apt-get -y install ghostscript \
libfreetype6-dev \
python3-dev \
supervisor \
git-core \
make && \
apt-get clean && \
# Download additional nginx modules
mkdir -p /tmp/modules && \
cd /tmp/modules && \
wget -O nginx-requestid.tar.gz https://github.com/hhru/nginx_requestid/archive/master.tar.gz && \
tar xvzf nginx-requestid.tar.gz && \
# Download and compile nginx
cd /tmp && \
wget http://nginx.org/download/nginx-${NGINX_VERSION}.tar.gz && \
tar xzvf nginx-${NGINX_VERSION}.tar.gz && \
cd nginx-${NGINX_VERSION} && \
./configure ${NGINX_OPTS} && \
make && \
make install && \
pip install --upgrade pip && \
pip install --no-cache-dir -r /opt/app/requirements/production.txt && \
# Delete build dependencies after use
cd /tmp \
&& rm -rf \
modules \
nginx-${NGINX_VERSION} \
nginx-${NGINX_VERSION}.tar.gz \
/var/cache/apt/* \
/root/.cache \
/var/lib/apt/lists/*
# for gitlab cli
#COPY . /opt/app
#VOLUME ["/opt/app/public/media"]
WORKDIR /opt/app
RUN rm -v /etc/nginx/nginx.conf
ADD /conf/nginx.conf /etc/nginx/
EXPOSE 80
CMD ["conf/docker/entrypoint_stage.sh"]

@ -22,8 +22,8 @@ python3 manage.py migrate myauth --noinput
python3 manage.py migrate --noinput
pip3 install -r requirements/test.txt
python3 manage.py dummydata --number 100 # Load dummy data for testing interface
#pip3 install -r requirements/test.txt
#python3 manage.py dummydata --number 100 # Load dummy data for testing interface
supervisord -c /opt/app/conf/supervisor.conf

Loading…
Cancel
Save