update
This commit is contained in:
25
docker/nginx/updatesdashboard.conf
Normal file
25
docker/nginx/updatesdashboard.conf
Normal file
@@ -0,0 +1,25 @@
|
||||
server {
|
||||
listen 3000;
|
||||
server_name updates-dashboard.hyrule.ovh;
|
||||
|
||||
# css, js…
|
||||
location /static {
|
||||
alias /app/static;
|
||||
}
|
||||
|
||||
if ($request_uri !~ "^/admin.*") {
|
||||
# don't rewrite admin
|
||||
rewrite ^/(.*)/$ /$1 permanent;
|
||||
}
|
||||
|
||||
location / {
|
||||
include proxy_params;
|
||||
proxy_pass http://127.0.0.1:3001;
|
||||
proxy_connect_timeout 120s;
|
||||
proxy_read_timeout 300s;
|
||||
|
||||
}
|
||||
|
||||
error_log /var/log/updatesdashboard-error.log;
|
||||
access_log /var/log/updatesdashboard-access.log;
|
||||
}
|
||||
@@ -2,7 +2,7 @@
|
||||
until nc -vz $1 $2; do echo "Waiting for MySQL $1:$2..."; sleep 3; done;
|
||||
|
||||
python /app/manage.py migrate
|
||||
python /app/manage.py collectstatic
|
||||
python /app/manage.py collectstatic --clear --no-input
|
||||
python /app/manage.py loaddata /app/dashboard/fixtures/os.yaml
|
||||
python /app/manage.py createsuperuser --noinput --username admin --email test@example.com
|
||||
service nginx start
|
||||
|
||||
@@ -1,8 +1,11 @@
|
||||
#!/bin/sh
|
||||
until nc -vz $1 $2; do echo "Waiting for MySQL $1:$2..."; sleep 3; done;
|
||||
|
||||
#python /app/manage.py flush --no-input
|
||||
#python /app/manage.py migrate
|
||||
#python /app/manage.py loaddata dashboard/fixtures/os.yaml
|
||||
python /app/manage.py migrate
|
||||
python /app/manage.py collectstatic
|
||||
python /app/manage.py loaddata /app/dashboard/fixtures/os.yaml
|
||||
python /app/manage.py createsuperuser --noinput --username admin --email test@example.com
|
||||
service nginx start
|
||||
gunicorn updatesdashboard.wsgi:application
|
||||
|
||||
exec "$@"
|
||||
|
||||
Reference in New Issue
Block a user