Anpassungen, damit Real-IP weitergereicht wird

This commit is contained in:
phil 2021-07-29 20:26:37 +02:00
parent 48e995e215
commit cc0b9a729e
2 changed files with 5 additions and 6 deletions

View file

@ -14,8 +14,9 @@ server {
location /ws { location /ws {
proxy_set_header Upgrade $http_upgrade; proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade"; proxy_set_header Connection "Upgrade";
proxy_set_header Host $host;
proxy_pass http://{{ zammad_host }}:80; proxy_pass http://{{ zammad_host }}:80;
} }
location / { proxy_pass http://{{ zammad_host }}:80; } location / {
proxy_pass http://{{ zammad_host }}:80;
}
} }

View file

@ -15,8 +15,7 @@ server {
proxy_http_version 1.1; proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade; proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade"; proxy_set_header Connection "Upgrade";
proxy_set_header CLIENT_IP $remote_addr; proxy_set_header CLIENT_IP $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme; proxy_set_header X-Forwarded-Proto $scheme;
proxy_read_timeout 86400; proxy_read_timeout 86400;
proxy_pass http://127.0.0.1:6042; proxy_pass http://127.0.0.1:6042;
@ -24,8 +23,7 @@ server {
location / { location / {
proxy_set_header Host $http_host; proxy_set_header Host $http_host;
proxy_set_header CLIENT_IP $remote_addr; proxy_set_header CLIENT_IP $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto https; proxy_set_header X-Forwarded-Proto https;
# Change this line in an SSO setup # Change this line in an SSO setup
proxy_set_header X-Forwarded-User ""; proxy_set_header X-Forwarded-User "";