Skip to content

Commit 62ad51c

Browse files
committed
feat: add SAML2 login configuration and update Dockerfile
1 parent cc46958 commit 62ad51c

3 files changed

Lines changed: 9 additions & 9 deletions

File tree

frontend/Dockerfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ FROM nginx:1.19.5
22
WORKDIR /usr/share/nginx/html
33
COPY ./nginx/mime.types /etc/nginx/mime.types
44
COPY ./dist/utm-stack/ /usr/share/nginx/html/
5+
COPY ./nginx/conf.d/*.conf /etc/nginx/conf.d/
56

67
HEALTHCHECK --start-period=120s --interval=60s --timeout=60s \
78
CMD curl --insecure -I -f http://localhost/health && curl --insecure -I -f http://localhost/api/ping || exit 1

frontend/nginx/conf/saml.conf

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
location /login/saml2/ {
2+
proxy_pass $utmstack_saml2;
3+
proxy_http_version 1.1;
4+
proxy_set_header Host $host;
5+
proxy_set_header X-Real-IP $remote_addr;
6+
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
7+
proxy_set_header X-Forwarded-Proto $scheme;
8+
}

installer/templates/front-end.go

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -19,15 +19,6 @@ const FrontEnd string = `server {
1919
set $shared_key {{.SharedKey}};
2020
set $shared_key_header $http_x_shared_key;
2121
22-
location /login/saml2/ {
23-
proxy_pass $utmstack_saml2;
24-
proxy_http_version 1.1;
25-
proxy_set_header Host $host;
26-
proxy_set_header X-Real-IP $remote_addr;
27-
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
28-
proxy_set_header X-Forwarded-Proto $scheme;
29-
}
30-
3122
location /api {
3223
proxy_pass $utmstack_backend;
3324
proxy_set_header Host $host;

0 commit comments

Comments
 (0)