ch prefix
This commit is contained in:
30
backend/deployment/nginx-public.conf
Normal file
30
backend/deployment/nginx-public.conf
Normal file
@@ -0,0 +1,30 @@
|
||||
# Snippet: /public → Go backend (Static serve)
|
||||
# Include inside the tbbank.gov.tm server { } block, e.g.:
|
||||
# include /var/www/tbbank/backend/deployment/nginx-public.conf;
|
||||
#
|
||||
# Or paste the location blocks into the existing site config.
|
||||
|
||||
# Uploaded / CMS media: /public/images/...
|
||||
location /public/ {
|
||||
proxy_pass http://127.0.0.1:5050;
|
||||
proxy_http_version 1.1;
|
||||
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;
|
||||
|
||||
# optional cache for static assets
|
||||
proxy_cache_valid 200 1h;
|
||||
expires 1h;
|
||||
add_header Cache-Control "public";
|
||||
}
|
||||
|
||||
# MinIO-backed images via backend handler (if used)
|
||||
location /images/ {
|
||||
proxy_pass http://127.0.0.1:5050;
|
||||
proxy_http_version 1.1;
|
||||
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;
|
||||
}
|
||||
Reference in New Issue
Block a user