forked from comcc/PaddlePaddle.org
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
31 lines (25 loc) · 1.01 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
############################################################
# Dockerfile to run a Django-based web application
# Based on an AMI
# https://medium.com/@rohitkhatana/deploying-django-app-on-aws-ecs-using-docker-gunicorn-nginx-c90834f76e21
############################################################
# Set the base image to use to Ubuntu
FROM ubuntu:16.04
# Set the file maintainer (your name - the file's author)
MAINTAINER Thuan Nguyen
# Update the default application repository sources list
RUN apt-get update && apt-get install -y \
python-setuptools python-dev build-essential python-pip \
nginx gettext nodejs
# Create application subdirectories
WORKDIR /var/www
COPY . .
# Port to expose
EXPOSE 8000
WORKDIR /var/www/portal
RUN pip install -r requirements.txt
COPY ./docker-entrypoint.sh .
COPY ./django_nginx.conf /etc/nginx/sites-available/
RUN ln -s /etc/nginx/sites-available/django_nginx.conf /etc/nginx/sites-enabled
RUN echo "daemon off;" >> /etc/nginx/nginx.conf
ENTRYPOINT ["./docker-entrypoint.sh"]