prod build fix
This commit is contained in:
@@ -8,11 +8,6 @@ upstream backend_upstream {
|
||||
keepalive 16;
|
||||
}
|
||||
|
||||
map $uri $static_file {
|
||||
~*\.(?:css|js|mjs|png|jpg|jpeg|gif|svg|ico|webp|woff2?)$ 1;
|
||||
default 0;
|
||||
}
|
||||
|
||||
server {
|
||||
listen 80;
|
||||
server_name _;
|
||||
@@ -53,13 +48,13 @@ server {
|
||||
proxy_pass http://backend_upstream/redoc;
|
||||
}
|
||||
|
||||
location ~* \.(?:css|js|mjs|png|jpg|jpeg|gif|svg|ico|webp|woff2?)$ {
|
||||
proxy_pass http://frontend_upstream;
|
||||
add_header Cache-Control "public, max-age=31536000, immutable" always;
|
||||
}
|
||||
|
||||
location / {
|
||||
proxy_pass http://frontend_upstream;
|
||||
|
||||
if ($static_file) {
|
||||
add_header Cache-Control "public, max-age=31536000, immutable" always;
|
||||
}
|
||||
|
||||
add_header Cache-Control "no-store, no-cache" always;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user