From 6251386aa82b2b410d9564b46a0ad6e4213fbd7f Mon Sep 17 00:00:00 2001 From: Joe Heffer Date: Wed, 8 Jan 2025 14:30:06 +0000 Subject: [PATCH] Revert Gunicorn socket path --- config/nginx/gunicorn.conf | 2 +- config/systemd/gunicorn.socket | 2 +- deploy.sh | 3 ++- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/config/nginx/gunicorn.conf b/config/nginx/gunicorn.conf index 1db1949..0818575 100644 --- a/config/nginx/gunicorn.conf +++ b/config/nginx/gunicorn.conf @@ -3,7 +3,7 @@ upstream app_server { # fail_timeout=0 means we always retry an upstream even if it failed # to return a good HTTP response # for UNIX domain socket setups - server unix:/run/gunicorn/gunicorn.sock fail_timeout=0; + server unix:/run/gunicorn.sock fail_timeout=0; } server { diff --git a/config/systemd/gunicorn.socket b/config/systemd/gunicorn.socket index 34e7342..3bc872e 100644 --- a/config/systemd/gunicorn.socket +++ b/config/systemd/gunicorn.socket @@ -4,7 +4,7 @@ Description=gunicorn socket [Socket] -ListenStream=/run/gunicorn/gunicorn.sock +ListenStream=/run/gunicorn.sock # Our service won't need permissions for the socket, since it # inherits the file descriptor by socket activation. # Only the nginx daemon will need access to the socket: diff --git a/deploy.sh b/deploy.sh index a74de25..44887ab 100644 --- a/deploy.sh +++ b/deploy.sh @@ -42,5 +42,6 @@ apt install --yes -qq nginx # Configure web server rm -f /etc/nginx/sites-enabled/default cp config/nginx/*.conf /etc/nginx/sites-available -ln -s /etc/nginx/sites-available/gunicorn.conf /etc/nginx/sites-enabled/gunicorn.conf +# Enable the site by creating a symbolic link +ln --symbolic --force /etc/nginx/sites-available/gunicorn.conf /etc/nginx/sites-enabled/gunicorn.conf systemctl reload nginx.service