argos/deployment/proxy/ProxyNginx.conf

95 lines
3.7 KiB
Plaintext
Raw Normal View History

2024-04-25 10:48:25 +02:00
server {
listen 8080;
2024-05-09 16:55:24 +02:00
server_name host.docker.internal:8081;
location ~/.well-known {
allow all;
root /var/www/html/test;
}
2024-04-25 10:48:25 +02:00
}
2024-05-09 16:55:24 +02:00
server {
listen 8081;
2024-05-09 16:55:24 +02:00
server_name host.docker.internal;
proxy_pass_header Server;
2024-04-25 10:48:25 +02:00
# add_header X-XSS-Protection "1; mode=block" always;
# add_header X-Content-Type-Options nosniff;
# add_header Strict-Transport-Security "max-age=63072000; includeSubDomains; preload";
# add_header Referrer-Policy 'strict-origin' always;
# add_header Feature-Policy "usb 'none'; xr-spatial-tracking 'none'" always;
# add_header Permissions-Policy "geolocation=(),sync-xhr=(),microphone=(),camera=(),magnetometer=(),gyroscope=()" always;
2024-04-25 10:48:25 +02:00
location / {
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
# Fix the “It appears that your reverse proxy set up is broken" error.
2024-05-09 16:55:24 +02:00
proxy_pass http://opencdmp.frontend:8080;
proxy_read_timeout 90;
2024-05-09 16:55:24 +02:00
proxy_redirect http://opencdmp.frontend:8080 http://host.docker.internal:8081;
}
location /api/ {
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
# Fix the “It appears that your reverse proxy set up is broken" error.
2024-05-09 16:55:24 +02:00
proxy_pass http://opencdmp.backend:8080;
proxy_read_timeout 90;
2024-05-09 16:55:24 +02:00
proxy_redirect http://opencdmp.backend:8080 http://host.docker.internal:8081/api;
}
2024-05-09 16:55:24 +02:00
# location /api/notification/ {
2024-05-09 16:55:24 +02:00
# proxy_set_header Host $host;
# proxy_set_header X-Real-IP $remote_addr;
# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
# proxy_set_header X-Forwarded-Proto $scheme;
2024-05-09 16:55:24 +02:00
# # Fix the “It appears that your reverse proxy set up is broken" error.
# proxy_pass http://opencdmp.notification:8080;
# proxy_read_timeout 90;
# proxy_redirect http://opencdmp.notification:8080 http://host.docker.internal:8081/api/notification;
# }
2024-05-09 16:55:24 +02:00
# location /api/annotation/ {
2024-05-09 16:55:24 +02:00
# proxy_set_header Host $host;
# proxy_set_header X-Real-IP $remote_addr;
# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
# proxy_set_header X-Forwarded-Proto $scheme;
2024-05-09 16:55:24 +02:00
# # Fix the “It appears that your reverse proxy set up is broken" error.
# proxy_pass http://opencdmp.annotation:8080;
# proxy_read_timeout 90;
# proxy_redirect http://opencdmp.annotation:8080 http://host.docker.internal:8081/api/annotation;
# }
2024-04-25 10:48:25 +02:00
location /keycloak/ {
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header X-Forwarded-Port $server_port;
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Forwarded-Server $host;
# Fix the “It appears that your reverse proxy set up is broken" error.
2024-05-09 16:55:24 +02:00
proxy_pass http://opencdmp.keycloak:8080;
2024-04-25 10:48:25 +02:00
proxy_read_timeout 90;
2024-05-09 16:55:24 +02:00
proxy_redirect http://opencdmp.keycloak:8080 http://host.docker.internal:8081/keycloak;
2024-04-25 10:48:25 +02:00
}
}