fix: correct sed command and paths in docker-compose.prod.yml for proper nginx config generation
This commit is contained in:
@@ -38,14 +38,14 @@ services:
|
|||||||
sh -c "python manage.py migrate --noinput &&
|
sh -c "python manage.py migrate --noinput &&
|
||||||
python manage.py collectstatic --noinput &&
|
python manage.py collectstatic --noinput &&
|
||||||
mkdir -p /nginx_configs_host/nginx &&
|
mkdir -p /nginx_configs_host/nginx &&
|
||||||
sed \"s|/home/user/app/dq-site|${HOST_PROJECT_PATH:-/home/default_user/projects/dq-site}|g\" /app/configs/nginx/dq-app--external-nginx.conf > /nginx_configs_host/nginx/nginx_dq.conf.example &&
|
sed \"s|/home/user/app/dq-site|${HOST_PROJECT_PATH:-/home/default_user/projects/dq-site}|g\" /home/app/web/config/nginx/dq-app--external-nginx.conf > /nginx_configs_host/nginx/nginx_dq.conf.example &&
|
||||||
if [ ! -f /nginx_configs_host/nginx/dq-app--external-nginx.conf ]; then
|
if [ ! -f /nginx_configs_host/nginx/dq-app--external-nginx.conf ]; then
|
||||||
cp /nginx_configs_host/nginx/nginx_dq.conf.example /nginx_configs_host/nginx/dq-app--external-nginx.conf;
|
cp /nginx_configs_host/nginx/nginx_dq.conf.example /nginx_configs_host/nginx/dq-app--external-nginx.conf;
|
||||||
echo 'INIT: Created new nginx config with correct paths';
|
echo 'INIT: Created new nginx config with correct paths';
|
||||||
fi &&
|
fi &&
|
||||||
mkdir -p /app/public/media/errors &&
|
mkdir -p /app/public/media/errors &&
|
||||||
cp /app/dicquo/templates/static_404.html /app/public/media/errors/404.html &&
|
cp /home/app/web/dicquo/templates/static_404.html /app/public/media/errors/404.html &&
|
||||||
cp /app/dicquo/templates/static_500.html /app/public/media/errors/500.html &&
|
cp /home/app/web/dicquo/templates/static_500.html /app/public/media/errors/500.html &&
|
||||||
gunicorn --workers 3 --bind 0.0.0.0:8000 dicquo.wsgi:application"
|
gunicorn --workers 3 --bind 0.0.0.0:8000 dicquo.wsgi:application"
|
||||||
|
|
||||||
# 4. Проброс портов (Внешний Nginx -> localhost:8010)
|
# 4. Проброс портов (Внешний Nginx -> localhost:8010)
|
||||||
|
|||||||
Reference in New Issue
Block a user