forked from ASKBOT/askbot-devel
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
26 lines (18 loc) · 654 Bytes
/
Dockerfile
File metadata and controls
26 lines (18 loc) · 654 Bytes
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
FROM python:2
ENV PYTHONUNBUFFERED 1
ADD . /src/
WORKDIR /src/
RUN pip install -r askbot_requirements.txt
RUN python setup.py install
RUN mkdir /site/
WORKDIR /site/
RUN askbot-setup --dir-name=. --db-engine=${ASKBOT_DATABASE_ENGINE:-2} \
--db-name=${ASKBOT_DATABASE_NAME:-db.sqlite} \
--db-user="${ASKBOT_DATABASE_USER}" \
--db-password="${ASKBOT_DATABASE_PASSWORD}" \
--domain="${ASKBOT_DOMAIN:-example.com}"
RUN sed "s/ROOT_URLCONF.*/ROOT_URLCONF = 'urls'/" settings.py -i
RUN python manage.py migrate --noinput
RUN python manage.py collectstatic --noinput
CMD ["python", "manage.py", "runserver", "0.0.0.0:8080"]
EXPOSE 8080