You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

28 lines
713 B

FROM python:3.6
ENV PYTHONUNBUFFERED 1
COPY requirements /opt/app/requirements
RUN apt-get update -y && \
apt-get upgrade -y && \
apt-get -y install ghostscript libfreetype6-dev python3-dev nginx supervisor make && \
apt-get clean && \
rm -rf /var/lib/apt/lists/* && \
pip install --upgrade pip && \
pip install --no-cache-dir -r /opt/app/requirements/production.txt && \
# Nginx
chown -R www-data:www-data /var/lib/nginx && \
# Delete build dependencies after use
rm -r /root/.cache
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"]