Skip to content

Commit

Permalink
fix(?): Add basic auth token for probes
Browse files Browse the repository at this point in the history
  • Loading branch information
trev-dev committed Nov 18, 2024
1 parent 092e49f commit f7b5829
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/workflows/deploy-to-openshift-backend-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,7 @@ jobs:
-p MAX_MEM=${{ env.MAX_MEM_NGINX }} \
-p HOST_ROUTE=${{ secrets.NGINX_HOST_ROUTE }} \
-p APP_ENVIRONMENT=${{ env.APP_ENVIRONMENT }} \
-p NGINX_BASIC_AUTH_TOKEN=${{ secrets.NGINX_BASIC_AUTH_TOKEN }} \
| oc apply -f -
cat <<- \EOF | sed 's/^ \+//g' > /tmp/nginx_htpasswd
Expand Down
9 changes: 9 additions & 0 deletions tools/openshift/nginx.deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,9 @@ objects:
path: /
port: 8080
scheme: HTTP
httpHeaders:
- name: Authorization
value: "Basic ${NGINX_BASIC_AUTH_TOKEN}"
periodSeconds: 10
successThreshold: 1
timeoutSeconds: 1
Expand All @@ -54,6 +57,9 @@ objects:
path: /
port: 8080
scheme: HTTP
httpHeaders:
- name: Authorization
value: "Basic ${NGINX_BASIC_AUTH_TOKEN}"
periodSeconds: 10
successThreshold: 1
timeoutSeconds: 1
Expand Down Expand Up @@ -170,3 +176,6 @@ parameters:
- name: HOST_ROUTE
description: The internal route for routing nginx traffic
required: true
- name: NGINX_BASIC_AUTH_TOKEN
description: The basic authentication for liveness/readiness probes
required: true

0 comments on commit f7b5829

Please sign in to comment.