Commit e30d2dda authored by Rajesh's avatar Rajesh
Browse files

removing unnecessary nginx paths

No related merge requests found
Showing with 0 additions and 116 deletions
+0 -116
...@@ -133,122 +133,6 @@ proxyconfig: | ...@@ -133,122 +133,6 @@ proxyconfig: |
proxy_pass http://kong; proxy_pass http://kong;
} }
# Oauth2 config
location /oauth2/ {
set $target http://{{swarm_dashboard}}:4111;
proxy_pass $target;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Scheme $scheme;
proxy_set_header X-Auth-Request-Redirect $request_uri;
}
location = /oauth2/auth {
set $target http://{{swarm_dashboard}}:4111;
proxy_pass $target;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Scheme $scheme;
# nginx auth_request includes headers but not body
proxy_set_header Content-Length "";
proxy_pass_request_body off;
}
location /dashboard/ {
auth_request /oauth2/auth;
error_page 401 = /oauth2/sign_in;
# Setting target url
auth_request_set $target http://{{swarm_dashboard}}:5601;
# pass information via X-User and X-Email headers to backend,
# requires running with --set-xauthrequest flag
auth_request_set $user $upstream_http_x_auth_request_user;
auth_request_set $email $upstream_http_x_auth_request_email;
proxy_set_header X-User $user;
proxy_set_header X-Email $email;
# if you enabled --cookie-refresh, this is needed for it to work with auth_request
auth_request_set $auth_cookie $upstream_http_set_cookie;
add_header Set-Cookie $auth_cookie;
rewrite ^/dashboard/(.*) /$1 break;
proxy_pass $target;
}
location /dashboard-old/ {
auth_request /oauth2/auth;
error_page 401 = /oauth2/sign_in;
# Setting target url
auth_request_set $target http://{{swarm_dashboard}}:5602;
# pass information via X-User and X-Email headers to backend,
# requires running with --set-xauthrequest flag
auth_request_set $user $upstream_http_x_auth_request_user;
auth_request_set $email $upstream_http_x_auth_request_email;
proxy_set_header X-User $user;
proxy_set_header X-Email $email;
# if you enabled --cookie-refresh, this is needed for it to work with auth_request
auth_request_set $auth_cookie $upstream_http_set_cookie;
add_header Set-Cookie $auth_cookie;
rewrite ^/dashboard-old/(.*) /$1 break;
proxy_pass $target;
}
location /pipeline-dashboard/ {
auth_request /oauth2/auth;
error_page 401 = /oauth2/sign_in;
# Setting Target url
auth_request_set $target http://{{ ep_es_host}}:5601;
# pass information via X-User and X-Email headers to backend,
# requires running with --set-xauthrequest flag
auth_request_set $user $upstream_http_x_auth_request_user;
auth_request_set $email $upstream_http_x_auth_request_email;
proxy_set_header X-User $user;
proxy_set_header X-Email $email;
# if you enabled --cookie-refresh, this is needed for it to work with auth_request
auth_request_set $auth_cookie $upstream_http_set_cookie;
add_header Set-Cookie $auth_cookie;
rewrite ^/pipeline-dashboard/(.*) /$1 break;
proxy_pass $target;
}
location /grafana/ {
set $target http://{{swarm_dashboard}}:3001;
rewrite ^/grafana/(.*) /$1 break;
proxy_pass $target;
}
{% if proxy_prometheus==true %}
location /{{prometheus_alertmanager_route_prefix}}/ {
set $target http://monitor_alertmanager:9093;
rewrite ^/{{prometheus_alertmanager_route_prefix}}/(.*) /{{prometheus_alertmanager_route_prefix}}/$1 break;
proxy_pass $target;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Scheme $scheme;
proxy_connect_timeout 1;
proxy_send_timeout 30;
proxy_read_timeout 40;
auth_basic "Prometheus Alert manager";
auth_basic_user_file /run/secrets/prom_admin_creds;
}
location /{{prometheus_route_prefix}}/ {
set $target http://monitor_prometheus:9090;
rewrite ^/(.*) /$1 break;
proxy_pass $target;
}
{% endif %}
location /encryption/ { location /encryption/ {
set $target http://encryption-service:8013; set $target http://encryption-service:8013;
rewrite ^/encryption/(.*) /$1 break; rewrite ^/encryption/(.*) /$1 break;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment