From 6d46a2a5de85151c4dcfede20296bcb0de9b4339 Mon Sep 17 00:00:00 2001 From: makram89 Date: Sun, 30 Jan 2022 18:23:31 +0100 Subject: [PATCH] wsgi fix --- MUOR/MUOR/configs/muor.conf | 10 +++++----- MUOR/MUOR/configs/muor_after_location_block.conf | 6 +++--- MUOR/MUOR/configs/muor_before_location_block.conf | 9 ++++++--- MUOR/MUOR/configs/uwsgi.ini | 2 +- 4 files changed, 15 insertions(+), 12 deletions(-) diff --git a/MUOR/MUOR/configs/muor.conf b/MUOR/MUOR/configs/muor.conf index 9b9a83e17..b1f78e45a 100644 --- a/MUOR/MUOR/configs/muor.conf +++ b/MUOR/MUOR/configs/muor.conf @@ -4,8 +4,8 @@ map $http_upgrade $connection_upgrade { } upstream django { -# server localhost:8080; - server unix:///home/randomsec/RandomSec/uwsgi-file/muor.sock; + server localhost:8080; +# server unix:///home/randomsec/RandomSec/uwsgi-file/muor.sock; } @@ -54,9 +54,9 @@ server { # Finally, send all non-media requests to the Django server. location / { if ($cookie_sessionid = ""){ -# proxy_pass http://django; # TODO prolly change that to uwsgi_pass - uwsgi_pass django; - include /etc/nginx/uwsgi_params; + proxy_pass http://django; # TODO prolly change that to uwsgi_pass +# uwsgi_pass django; +# include /etc/nginx/uwsgi_params; } diff --git a/MUOR/MUOR/configs/muor_after_location_block.conf b/MUOR/MUOR/configs/muor_after_location_block.conf index 8ea977999..5cb053f1f 100644 --- a/MUOR/MUOR/configs/muor_after_location_block.conf +++ b/MUOR/MUOR/configs/muor_after_location_block.conf @@ -1,8 +1,8 @@ if ($cookie_sessionid = ""){ -# proxy_pass http://django; # TODO prolly change that to uwsgi_pass - uwsgi_pass django; - include /etc/nginx/uwsgi_params; + proxy_pass http://django; # TODO prolly change that to uwsgi_pass +# uwsgi_pass django; +# include /etc/nginx/uwsgi_params; } } diff --git a/MUOR/MUOR/configs/muor_before_location_block.conf b/MUOR/MUOR/configs/muor_before_location_block.conf index 2e101136d..8417efe47 100644 --- a/MUOR/MUOR/configs/muor_before_location_block.conf +++ b/MUOR/MUOR/configs/muor_before_location_block.conf @@ -6,7 +6,9 @@ map $http_upgrade $connection_upgrade { } upstream django { - server unix:///home/randomsec/RandomSec/uwsgi-file/muor.sock; +# server unix:///home/randomsec/RandomSec/uwsgi-file/muor.sock; + server localhost:8080; + } server { @@ -46,8 +48,9 @@ server { } location /logout/ { - uwsgi_pass django; - include /etc/nginx/uwsgi_params; +# uwsgi_pass django; +# include /etc/nginx/uwsgi_params; + proxy_pass http://django; # TODO prolly change that to uwsgi_pass } # Finally, send all non-media requests to the Django server. diff --git a/MUOR/MUOR/configs/uwsgi.ini b/MUOR/MUOR/configs/uwsgi.ini index 516ce170d..731b24b9c 100644 --- a/MUOR/MUOR/configs/uwsgi.ini +++ b/MUOR/MUOR/configs/uwsgi.ini @@ -6,5 +6,5 @@ pidfile=/home/randomsec/uwsgi-file/project-master.pid vacuum=True max-requests=5000 daemonize=/home/randomsec/RandomSec/log/logs.log -socket=/home/randomsec/RandomSec/uwsgi-file/muor.sock +http=:8080