🔧 Use regex-based api,saml locations without base path

This commit is contained in:
tiptophelmet 2025-03-24 21:05:27 +02:00
parent 9b3c24927c
commit eedd129a54

View File

@ -20,8 +20,8 @@ data:
client_header_buffer_size 32k;
large_client_header_buffers 8 64k;
location {{ default "" (((.Values.tap).routing).front).basePath }}/api {
rewrite ^{{ default "" (((.Values.tap).routing).front).basePath }}/api(.*)$ $1 break;
location ~ ^(/.+)?/api {
rewrite ^(/.+)?/api(.*)$ $2 break;
proxy_pass http://kubeshark-hub;
proxy_set_header X-Forwarded-For $remote_addr;
proxy_set_header Host $http_host;
@ -35,8 +35,8 @@ data:
proxy_pass_request_headers on;
}
location {{ default "" (((.Values.tap).routing).front).basePath }}/saml {
rewrite ^{{ default "" (((.Values.tap).routing).front).basePath }}/saml(.*)$ /saml$1 break;
location ~ ^(/.+)?/saml {
rewrite ^(/.+)?/saml(.*)$ /saml$2 break;
proxy_pass http://kubeshark-hub;
proxy_set_header X-Forwarded-For $remote_addr;
proxy_set_header Host $http_host;