From e9614bd9941e24b7d6f71ca92401ffcf98ac229b Mon Sep 17 00:00:00 2001 From: Mikhail Date: Wed, 17 Apr 2024 03:32:12 +0000 Subject: [PATCH] Update default.conf --- default.conf | 83 ++++++++++++++++++++++++++++++++++++++-------------- 1 file changed, 61 insertions(+), 22 deletions(-) diff --git a/default.conf b/default.conf index fcd9f8e..4fb0fdb 100644 --- a/default.conf +++ b/default.conf @@ -8,6 +8,14 @@ server { server_name hbpn.link; # managed by Certbot client_max_body_size 70M; + + add_header Last-Modified $date_gmt; + add_header Cache-Control 'private no-store, no-cache, must-revalidate, proxy-revalidate, max-age=0'; + if_modified_since off; + expires off; + etag off; + + location /404 { try_files $uri $uri/ /index.html; } @@ -51,6 +59,14 @@ server { server_name quiz.pena.digital; # managed by Certbot client_max_body_size 70M; + + add_header Last-Modified $date_gmt; + add_header Cache-Control 'private no-store, no-cache, must-revalidate, proxy-revalidate, max-age=0'; + if_modified_since off; + expires off; + etag off; + + location /404 { try_files $uri $uri/ /index.html; } @@ -59,13 +75,14 @@ server { proxy_hide_header Access-Control-Allow-Origin; add_header Access-Control-Allow-Origin quiz.pena.digital always; add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; proxy_pass http://10.8.0.8:59300; } location /user/ { add_header Access-Control-Allow-Origin quiz.pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type,authorization always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_pass http://10.8.0.8:59300; } @@ -73,7 +90,7 @@ server { location /heruvym/ { add_header Access-Control-Allow-Origin quiz.pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type,authorization,sess always; + add_header Access-Control-Allow-Headers content-type,authorization,sess,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; @@ -88,7 +105,7 @@ server { location /strator/ { add_header Access-Control-Allow-Origin quiz.pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type,authorization always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_pass http://10.8.0.8:59303/; } @@ -96,7 +113,7 @@ server { location /customer/ { add_header Access-Control-Allow-Origin quiz.pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type,authorization always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_pass http://10.8.0.8:8065/; } @@ -104,7 +121,7 @@ server { location /codeword/ { add_header Access-Control-Allow-Origin quiz.pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type,authorization always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_pass http://10.8.0.8:59664/; } @@ -112,7 +129,7 @@ server { location /price/ { add_header Access-Control-Allow-Origin quiz.pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type,authorization always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_pass http://10.8.0.8:8001/; } @@ -120,7 +137,7 @@ server { location /verification1 { add_header Access-Control-Allow-Origin quiz.pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type always; + add_header Access-Control-Allow-Headers content-type,response-type always; add_header Access-Control-Allow-Methods GET; chunked_transfer_encoding off; proxy_buffering off; @@ -131,7 +148,7 @@ server { location /answer/ { add_header Access-Control-Allow-Origin quiz.pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type,x-sessionkey always; + add_header Access-Control-Allow-Headers content-type,x-sessionkey,response-type always; add_header Access-Control-Expose-Headers x-sessionkey always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_pass http://10.8.0.9:1490/; @@ -140,7 +157,7 @@ server { location /squiz/ { add_header Access-Control-Allow-Origin quiz.pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type,authorization always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_pass http://10.8.0.9:1488/; } @@ -148,7 +165,7 @@ server { location /squizstorer/ { add_header Access-Control-Allow-Origin quiz.pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type,authorization always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; @@ -163,7 +180,7 @@ server { location /squizimages { add_header Access-Control-Allow-Origin quiz.pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type always; + add_header Access-Control-Allow-Headers content-type,response-type always; add_header Access-Control-Allow-Methods GET; chunked_transfer_encoding off; proxy_buffering off; @@ -190,6 +207,13 @@ server { try_files $uri $uri/ /index.html; } + add_header Last-Modified $date_gmt; + add_header Cache-Control 'private no-store, no-cache, must-revalidate, proxy-revalidate, max-age=0'; + if_modified_since off; + expires off; + etag off; + + location /404 { try_files $uri $uri/ /index.html; } @@ -208,7 +232,7 @@ server { location /user/ { add_header Access-Control-Allow-Origin hub.pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type,authorization always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_pass http://10.8.0.8:59300; } @@ -216,7 +240,7 @@ server { location /heruvym/ { add_header Access-Control-Allow-Origin hub.pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type,authorization,sess always; + add_header Access-Control-Allow-Headers content-type,authorization,sess,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; @@ -231,7 +255,7 @@ server { location /strator/ { add_header Access-Control-Allow-Origin hub.pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type,authorization always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_pass http://10.8.0.8:59303/; } @@ -239,7 +263,7 @@ server { location /customer/ { add_header Access-Control-Allow-Origin hub.pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type,authorization always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_pass http://10.8.0.8:8065/; } @@ -247,7 +271,7 @@ server { location /codeword/ { add_header Access-Control-Allow-Origin hub.pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type,authorization always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_pass http://10.8.0.8:59664/; } @@ -255,7 +279,7 @@ server { location /price/ { add_header Access-Control-Allow-Origin hub.pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type,authorization always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_pass http://10.8.0.8:8001/; } @@ -263,7 +287,7 @@ server { location /verification1 { add_header Access-Control-Allow-Origin hub.pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type always; + add_header Access-Control-Allow-Headers content-type,response-type always; add_header Access-Control-Allow-Methods GET; chunked_transfer_encoding off; proxy_buffering off; @@ -274,7 +298,7 @@ server { location /verification/ { add_header Access-Control-Allow-Origin hub.pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type,authorization always; + add_header Access-Control-Allow-Headers content-type,authorization,response-type always; add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; proxy_set_header Referer $host; proxy_set_header Origin $http_origin; @@ -301,6 +325,13 @@ server { try_files $uri $uri/ /index.html; } + add_header Last-Modified $date_gmt; + add_header Cache-Control 'private no-store, no-cache, must-revalidate, proxy-revalidate, max-age=0'; + if_modified_since off; + expires off; + etag off; + + location /404 { try_files $uri $uri/ /index.html; } @@ -308,7 +339,7 @@ server { location /feedback/ { add_header Access-Control-Allow-Origin pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type always; + add_header Access-Control-Allow-Headers content-type,response-type always; proxy_set_header Host $host; proxy_pass http://10.8.0.8:8006/; } @@ -331,6 +362,13 @@ server { try_files $uri $uri/ /index.html; } + add_header Last-Modified $date_gmt; + add_header Cache-Control 'private no-store, no-cache, must-revalidate, proxy-revalidate, max-age=0'; + if_modified_since off; + expires off; + etag off; + + location /404 { try_files $uri $uri/ /index.html; } @@ -338,7 +376,7 @@ server { location /feedback/ { add_header Access-Control-Allow-Origin pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type always; + add_header Access-Control-Allow-Headers content-type,response-type always; proxy_set_header Host $host; proxy_pass http://10.8.0.8:8006/; } @@ -357,6 +395,7 @@ server { index index.html index.htm index.nginx-debian.html; server_name solyanka.pena.digital; # managed by Certbot client_max_body_size 70M; + location /robots.txt { try_files $uri $uri/ /index.html; } @@ -368,7 +407,7 @@ server { location /feedback/ { add_header Access-Control-Allow-Origin pena.digital always; add_header Access-Control-Allow-Credentials true always; - add_header Access-Control-Allow-Headers content-type always; + add_header Access-Control-Allow-Headers content-type,response-type always; proxy_set_header Host $host; proxy_pass http://10.8.0.8:8006/; }