Skip to content

Instantly share code, notes, and snippets.

@houstondapaz
Created June 19, 2020 13:55
Show Gist options
  • Save houstondapaz/eefecfda4710a7c05beed343d8a87c5b to your computer and use it in GitHub Desktop.
Save houstondapaz/eefecfda4710a7c05beed343d8a87c5b to your computer and use it in GitHub Desktop.
ingress nginx configuration snippet
nginx.ingress.kubernetes.io/configuration-snippet: |
more_set_headers "Server:SEU_SERVER";
more_set_headers "cache-Control: no-cache, no-store";
more_set_headers "pragma: no-cache";
if ($request_uri ~* \.(?:ico|css|js|gif|jpe?g|png|svg|woff2|woff|ttf|eo|mp3)$) {
more_set_headers "cache-control: public, must-revalidate, proxy-revalidate";
more_set_headers "pragma: public";
expires max;
}
rewrite ^/SUB_PATH(/?)(.*)$ /$2 break;
rewrite /(.*)$ /$1 break;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment