mirror of
https://gitlab.science.ru.nl/technicie/MarietjeDjango.git
synced 2025-12-11 09:52:20 +01:00
Add Docker build and docker compose file
This commit is contained in:
31
resources/entrypoint.sh
Normal file
31
resources/entrypoint.sh
Normal file
@ -0,0 +1,31 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
set -e
|
||||
|
||||
touch -a /marietje/log/uwsgi.log
|
||||
touch -a /marietje/log/django.log
|
||||
|
||||
cd /marietje/src/website
|
||||
|
||||
./manage.py migrate --no-input
|
||||
./manage.py collectstatic --no-input
|
||||
|
||||
chown --recursive www-data:www-data /marietje/
|
||||
|
||||
echo "Starting uwsgi server."
|
||||
uwsgi --chdir=/marietje/src/website \
|
||||
--module=marietje.wsgi:application \
|
||||
--master --pidfile=/tmp/project-master.pid \
|
||||
--socket=:8000 \
|
||||
--processes=5 \
|
||||
--uid=www-data --gid=www-data \
|
||||
--harakiri=20 \
|
||||
--post-buffering=16384 \
|
||||
--max-requests=5000 \
|
||||
--thunder-lock \
|
||||
--vacuum \
|
||||
--logfile-chown \
|
||||
--logto2=/marietje/log/uwsgi.log \
|
||||
--ignore-sigpipe \
|
||||
--ignore-write-errors \
|
||||
--disable-write-exception
|
||||
Reference in New Issue
Block a user