Skip to content

Commit

Permalink
feat: change readiness and liveness checks to use script instead of h…
Browse files Browse the repository at this point in the history
…ttp call (#656)

Release-As: 1.8.39

Signed-off-by: iromli <[email protected]>
  • Loading branch information
iromli authored Aug 29, 2024
1 parent 87fedbc commit 3b61542
Show file tree
Hide file tree
Showing 20 changed files with 115 additions and 147 deletions.
55 changes: 24 additions & 31 deletions pygluu/kubernetes/templates/helm/gluu/README.md

Large diffs are not rendered by default.

6 changes: 2 additions & 4 deletions pygluu/kubernetes/templates/helm/gluu/charts/casa/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,13 +41,11 @@ Kubernetes: `>=v1.22.0-0`
| image.repository | string | `"gluufederation/casa"` | Image to use for deploying. |
| image.tag | string | `"4.5.5-1"` | Image tag to use for deploying. |
| lifecycle | object | `{}` | |
| livenessProbe | object | `{"httpGet":{"path":"/casa/health-check","port":"http-casa"},"initialDelaySeconds":25,"periodSeconds":25,"timeoutSeconds":5}` | Configure the liveness healthcheck for casa if needed. |
| livenessProbe.httpGet.path | string | `"/casa/health-check"` | http liveness probe endpoint |
| livenessProbe | object | `{"exec":{"command":["python3","/app/scripts/healthcheck.py"]},"initialDelaySeconds":25,"periodSeconds":25,"timeoutSeconds":5}` | Configure the liveness healthcheck for casa if needed. |
| nameOverride | string | `""` | |
| nodeSelector | object | `{}` | |
| podSecurityContext | object | `{}` | |
| readinessProbe | object | `{"httpGet":{"path":"/casa/health-check","port":"http-casa"},"initialDelaySeconds":30,"periodSeconds":30,"timeoutSeconds":5}` | Configure the readiness healthcheck for the casa if needed. |
| readinessProbe.httpGet.path | string | `"/casa/health-check"` | http readiness probe endpoint |
| readinessProbe | object | `{"exec":{"command":["python3","/app/scripts/healthcheck.py"]},"initialDelaySeconds":30,"periodSeconds":30,"timeoutSeconds":5}` | Configure the readiness healthcheck for the casa if needed. |
| replicas | int | `1` | Service replica number. |
| resources | object | `{"limits":{"cpu":"500m","memory":"500Mi"},"requests":{"cpu":"500m","memory":"500Mi"}}` | Resource specs. |
| resources.limits.cpu | string | `"500m"` | CPU limit. |
Expand Down
16 changes: 8 additions & 8 deletions pygluu/kubernetes/templates/helm/gluu/charts/casa/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -61,19 +61,19 @@ service:
timeoutSeconds: 10800
# -- Configure the liveness healthcheck for casa if needed.
livenessProbe:
httpGet:
# -- http liveness probe endpoint
path: /casa/health-check
port: http-casa
exec:
command:
- python3
- /app/scripts/healthcheck.py
initialDelaySeconds: 25
periodSeconds: 25
timeoutSeconds: 5
# -- Configure the readiness healthcheck for the casa if needed.
readinessProbe:
httpGet:
# -- http readiness probe endpoint
path: /casa/health-check
port: http-casa
exec:
command:
- python3
- /app/scripts/healthcheck.py
initialDelaySeconds: 30
periodSeconds: 30
timeoutSeconds: 5
Expand Down
5 changes: 2 additions & 3 deletions pygluu/kubernetes/templates/helm/gluu/charts/fido2/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,9 @@ Kubernetes: `>=v1.22.0-0`
| image.repository | string | `"gluufederation/fido2"` | Image to use for deploying. |
| image.tag | string | `"4.5.5-1"` | Image tag to use for deploying. |
| lifecycle | object | `{}` | |
| livenessProbe | object | `{"httpGet":{"path":"/fido2/restv1/fido2/configuration","port":"http-fido2"},"initialDelaySeconds":25,"periodSeconds":25,"timeoutSeconds":5}` | Configure the liveness healthcheck for the fido2 if needed. |
| livenessProbe.httpGet | object | `{"path":"/fido2/restv1/fido2/configuration","port":"http-fido2"}` | http liveness probe endpoint |
| livenessProbe | object | `{"exec":{"command":["python3","/app/scripts/healthcheck.py"]},"initialDelaySeconds":25,"periodSeconds":25,"timeoutSeconds":5}` | Configure the liveness healthcheck for the fido2 if needed. |
| nodeSelector | object | `{}` | |
| readinessProbe | object | `{"httpGet":{"path":"/fido2/restv1/fido2/configuration","port":"http-fido2"},"initialDelaySeconds":30,"periodSeconds":30,"timeoutSeconds":5}` | Configure the readiness healthcheck for the fido2 if needed. |
| readinessProbe | object | `{"exec":{"command":["python3","/app/scripts/healthcheck.py"]},"initialDelaySeconds":30,"periodSeconds":30,"timeoutSeconds":5}` | Configure the readiness healthcheck for the fido2 if needed. |
| replicas | int | `1` | Service replica number. |
| resources | object | `{"limits":{"cpu":"500m","memory":"500Mi"},"requests":{"cpu":"500m","memory":"500Mi"}}` | Resource specs. |
| resources.limits.cpu | string | `"500m"` | CPU limit. |
Expand Down
15 changes: 8 additions & 7 deletions pygluu/kubernetes/templates/helm/gluu/charts/fido2/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,18 +62,19 @@ service:
timeoutSeconds: 10800
# -- Configure the liveness healthcheck for the fido2 if needed.
livenessProbe:
# -- http liveness probe endpoint
httpGet:
path: /fido2/restv1/fido2/configuration
port: http-fido2
exec:
command:
- python3
- /app/scripts/healthcheck.py
initialDelaySeconds: 25
periodSeconds: 25
timeoutSeconds: 5
# -- Configure the readiness healthcheck for the fido2 if needed.
readinessProbe:
httpGet:
path: /fido2/restv1/fido2/configuration
port: http-fido2
exec:
command:
- python3
- /app/scripts/healthcheck.py
initialDelaySeconds: 30
periodSeconds: 30
timeoutSeconds: 5
Expand Down
4 changes: 2 additions & 2 deletions pygluu/kubernetes/templates/helm/gluu/charts/opendj/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ Kubernetes: `>=v1.22.0-0`
| lifecycle.preStop.exec.command[0] | string | `"/bin/sh"` | |
| lifecycle.preStop.exec.command[1] | string | `"-c"` | |
| lifecycle.preStop.exec.command[2] | string | `"python3 /app/scripts/deregister_peer.py 1>&/proc/1/fd/1"` | |
| livenessProbe | object | `{"exec":{"command":["python3","/app/scripts/healthcheck.py"]},"failureThreshold":20,"initialDelaySeconds":30,"periodSeconds":30,"timeoutSeconds":5}` | Configure the liveness healthcheck for OpenDJ if needed. https://github.com/GluuFederation/docker-opendj/blob/4.4/scripts/healthcheck.py |
| livenessProbe | object | `{"exec":{"command":["python3","/app/scripts/healthcheck.py"]},"failureThreshold":20,"initialDelaySeconds":30,"periodSeconds":30,"timeoutSeconds":5}` | Configure the liveness healthcheck for OpenDJ if needed. |
| livenessProbe.exec | object | `{"command":["python3","/app/scripts/healthcheck.py"]}` | Executes the python3 healthcheck. |
| nameOverride | string | `""` | |
| nodeSelector | object | `{}` | |
Expand All @@ -60,7 +60,7 @@ Kubernetes: `>=v1.22.0-0`
| persistence.size | string | `"5Gi"` | OpenDJ volume size |
| persistence.type | string | `"DirectoryOrCreate"` | |
| ports | object | `{"tcp-admin":{"nodePort":"","port":4444,"protocol":"TCP","targetPort":4444},"tcp-ldap":{"nodePort":"","port":1389,"protocol":"TCP","targetPort":1389},"tcp-ldaps":{"nodePort":"","port":1636,"protocol":"TCP","targetPort":1636},"tcp-repl":{"nodePort":"","port":8989,"protocol":"TCP","targetPort":8989},"tcp-serf":{"nodePort":"","port":7946,"protocol":"TCP","targetPort":7946},"udp-serf":{"nodePort":"","port":7946,"protocol":"UDP","targetPort":7946}}` | servicePorts values used in StatefulSet container |
| readinessProbe | object | `{"failureThreshold":20,"initialDelaySeconds":60,"periodSeconds":25,"tcpSocket":{"port":1636},"timeoutSeconds":5}` | Configure the readiness healthcheck for OpenDJ if needed. https://github.com/GluuFederation/docker-opendj/blob/4.4/scripts/healthcheck.py |
| readinessProbe | object | `{"failureThreshold":20,"initialDelaySeconds":60,"periodSeconds":25,"tcpSocket":{"port":1636},"timeoutSeconds":5}` | Configure the readiness healthcheck for OpenDJ if needed. |
| replicas | int | `1` | Service replica number. |
| resources | object | `{"limits":{"cpu":"1500m","memory":"2000Mi"},"requests":{"cpu":"1500m","memory":"2000Mi"}}` | Resource specs. |
| resources.limits.cpu | string | `"1500m"` | CPU limit. |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,6 @@ resources:
# -- Memory request.
memory: 2000Mi
# -- Configure the liveness healthcheck for OpenDJ if needed.
# https://github.com/GluuFederation/docker-opendj/blob/4.4/scripts/healthcheck.py
livenessProbe:
# -- Executes the python3 healthcheck.
exec:
Expand All @@ -95,7 +94,6 @@ livenessProbe:
timeoutSeconds: 5
failureThreshold: 20
# -- Configure the readiness healthcheck for OpenDJ if needed.
# https://github.com/GluuFederation/docker-opendj/blob/4.4/scripts/healthcheck.py
readinessProbe:
tcpSocket:
port: 1636
Expand Down
4 changes: 2 additions & 2 deletions pygluu/kubernetes/templates/helm/gluu/charts/oxauth/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,9 @@ Kubernetes: `>=v1.22.0-0`
| image.tag | string | `"4.5.5-1"` | Image tag to use for deploying. |
| lifecycle | object | `{}` | |
| livenessProbe | object | `{"exec":{"command":["python3","/app/scripts/healthcheck.py"]},"initialDelaySeconds":30,"periodSeconds":30,"timeoutSeconds":5}` | Configure the liveness healthcheck for the auth server if needed. |
| livenessProbe.exec | object | `{"command":["python3","/app/scripts/healthcheck.py"]}` | Executes the python3 healthcheck. https://github.com/GluuFederation/docker-oxauth/blob/4.3/scripts/healthcheck.py |
| livenessProbe.exec | object | `{"command":["python3","/app/scripts/healthcheck.py"]}` | Executes the python3 healthcheck. |
| nodeSelector | object | `{}` | |
| readinessProbe | object | `{"exec":{"command":["python3","/app/scripts/healthcheck.py"]},"initialDelaySeconds":25,"periodSeconds":25,"timeoutSeconds":5}` | Configure the readiness healthcheck for the auth server if needed. https://github.com/GluuFederation/docker-oxauth/blob/4.3/scripts/healthcheck.py |
| readinessProbe | object | `{"exec":{"command":["python3","/app/scripts/healthcheck.py"]},"initialDelaySeconds":25,"periodSeconds":25,"timeoutSeconds":5}` | Configure the readiness healthcheck for the auth server if needed. |
| replicas | int | `1` | Service replica number. |
| resources | object | `{"limits":{"cpu":"2500m","memory":"2500Mi"},"requests":{"cpu":"2500m","memory":"2500Mi"}}` | Resource specs. |
| resources.limits.cpu | string | `"2500m"` | CPU limit. |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ service:
# -- Configure the liveness healthcheck for the auth server if needed.
livenessProbe:
# -- Executes the python3 healthcheck.
# https://github.com/GluuFederation/docker-oxauth/blob/4.3/scripts/healthcheck.py
exec:
command:
- python3
Expand All @@ -71,7 +70,6 @@ livenessProbe:
periodSeconds: 30
timeoutSeconds: 5
# -- Configure the readiness healthcheck for the auth server if needed.
# https://github.com/GluuFederation/docker-oxauth/blob/4.3/scripts/healthcheck.py
readinessProbe:
exec:
command:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,10 @@ Kubernetes: `>=v1.22.0-0`
| image.repository | string | `"gluufederation/oxd-server"` | Image to use for deploying. |
| image.tag | string | `"4.5.5-1"` | Image tag to use for deploying. |
| lifecycle | object | `{}` | |
| livenessProbe | object | `{"exec":{"command":["curl","-k","http://localhost:8080/health-check"]},"initialDelaySeconds":30,"periodSeconds":30,"timeoutSeconds":5}` | Configure the liveness healthcheck for the auth server if needed. |
| livenessProbe.exec | object | `{"command":["curl","-k","http://localhost:8080/health-check"]}` | Executes the python3 healthcheck. |
| livenessProbe | object | `{"exec":{"command":["python3","/app/scripts/healthcheck.py"]},"initialDelaySeconds":30,"periodSeconds":30,"timeoutSeconds":5}` | Configure the liveness healthcheck for the auth server if needed. |
| livenessProbe.exec | object | `{"command":["python3","/app/scripts/healthcheck.py"]}` | Executes the python3 healthcheck. |
| nodeSelector | object | `{}` | |
| readinessProbe | object | `{"exec":{"command":["curl","-k","http://localhost:8080/health-check"]},"initialDelaySeconds":25,"periodSeconds":25,"timeoutSeconds":5}` | Configure the readiness healthcheck for the auth server if needed. |
| readinessProbe | object | `{"exec":{"command":["python3","/app/scripts/healthcheck.py"]},"initialDelaySeconds":25,"periodSeconds":25,"timeoutSeconds":5}` | Configure the readiness healthcheck for the auth server if needed. |
| replicas | int | `1` | Service replica number. |
| resources | object | `{"limits":{"cpu":"1000m","memory":"400Mi"},"requests":{"cpu":"1000m","memory":"400Mi"}}` | Resource specs. |
| resources.limits.cpu | string | `"1000m"` | CPU limit. |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,19 +60,17 @@ livenessProbe:
# -- Executes the python3 healthcheck.
exec:
command:
- curl
- -k
- http://localhost:8080/health-check
- python3
- /app/scripts/healthcheck.py
initialDelaySeconds: 30
periodSeconds: 30
timeoutSeconds: 5
# -- Configure the readiness healthcheck for the auth server if needed.
readinessProbe:
exec:
command:
- curl
- -k
- http://localhost:8080/health-check
- python3
- /app/scripts/healthcheck.py
initialDelaySeconds: 25
periodSeconds: 25
timeoutSeconds: 5
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,12 +40,10 @@ Kubernetes: `>=v1.22.0-0`
| image.repository | string | `"gluufederation/oxpassport"` | Image to use for deploying. |
| image.tag | string | `"4.5.5-1"` | Image tag to use for deploying. |
| lifecycle | object | `{}` | |
| livenessProbe | object | `{"failureThreshold":20,"httpGet":{"path":"/passport/health-check","port":"http-passport"},"initialDelaySeconds":30,"periodSeconds":30,"timeoutSeconds":5}` | Configure the liveness healthcheck for oxPassport if needed. |
| livenessProbe.httpGet.path | string | `"/passport/health-check"` | http liveness probe endpoint |
| livenessProbe | object | `{"exec":{"command":["python3","/app/scripts/healthcheck.py"]},"failureThreshold":20,"initialDelaySeconds":30,"periodSeconds":30,"timeoutSeconds":5}` | Configure the liveness healthcheck for oxPassport if needed. |
| nameOverride | string | `""` | |
| nodeSelector | object | `{}` | |
| readinessProbe | object | `{"failureThreshold":20,"httpGet":{"path":"/passport/health-check","port":"http-passport"},"initialDelaySeconds":25,"periodSeconds":25,"timeoutSeconds":5}` | Configure the readiness healthcheck for the oxPassport if needed. |
| readinessProbe.httpGet.path | string | `"/passport/health-check"` | http readiness probe endpoint |
| readinessProbe | object | `{"exec":{"command":["python3","/app/scripts/healthcheck.py"]},"failureThreshold":20,"initialDelaySeconds":25,"periodSeconds":25,"timeoutSeconds":5}` | Configure the readiness healthcheck for the oxPassport if needed. |
| replicas | int | `1` | Service replica number |
| resources | object | `{"limits":{"cpu":"700m","memory":"900Mi"},"requests":{"cpu":"700m","memory":"900Mi"}}` | Resource specs. |
| resources.limits.cpu | string | `"700m"` | CPU limit. |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,20 +61,20 @@ service:
timeoutSeconds: 10800
# -- Configure the liveness healthcheck for oxPassport if needed.
livenessProbe:
httpGet:
# -- http liveness probe endpoint
path: /passport/health-check
port: http-passport
exec:
command:
- python3
- /app/scripts/healthcheck.py
initialDelaySeconds: 30
periodSeconds: 30
timeoutSeconds: 5
failureThreshold: 20
# -- Configure the readiness healthcheck for the oxPassport if needed.
readinessProbe:
httpGet:
# -- http readiness probe endpoint
path: /passport/health-check
port: http-passport
exec:
command:
- python3
- /app/scripts/healthcheck.py
initialDelaySeconds: 25
periodSeconds: 25
timeoutSeconds: 5
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,11 +49,11 @@ Kubernetes: `>=v1.22.0-0`
| resources.requests.cpu | string | `"1000m"` | CPU request. |
| resources.requests.memory | string | `"1000Mi"` | Memory request. |
| service.livenessProbe | object | `{"exec":{"command":["python3","/app/scripts/healthcheck.py"]},"initialDelaySeconds":30,"periodSeconds":30,"timeoutSeconds":5}` | Configure the liveness healthcheck for the oxshibboleth if needed. |
| service.livenessProbe.exec | object | `{"command":["python3","/app/scripts/healthcheck.py"]}` | Executes the python3 healthcheck. https://github.com/GluuFederation/docker-oxshibboleth/blob/4.5/scripts/healthcheck.py |
| service.livenessProbe.exec | object | `{"command":["python3","/app/scripts/healthcheck.py"]}` | Executes the python3 healthcheck. |
| service.name | string | `"http-oxshib"` | Port of the oxShibboleth service. Please keep it as default. |
| service.oxShibbolethServiceName | string | `"oxshibboleth"` | Name of the oxShibboleth service. Please keep it as default. |
| service.port | int | `8080` | The name of the oxPassport port within the oxPassport service. Please keep it as default. |
| service.readinessProbe | object | `{"exec":{"command":["python3","/app/scripts/healthcheck.py"]}}` | Configure the readiness healthcheck for the oxshibboleth if needed. https://github.com/GluuFederation/docker-oxauth/blob/4.5/scripts/healthcheck.py |
| service.readinessProbe | object | `{"exec":{"command":["python3","/app/scripts/healthcheck.py"]}}` | Configure the readiness healthcheck for the oxshibboleth if needed. |
| service.sessionAffinity | string | `"None"` | Default set to None If you want to make sure that connections from a particular client are passed to the same Pod each time, you can select the session affinity based on the client's IP addresses by setting this to ClientIP |
| service.sessionAffinityConfig | object | `{"clientIP":{"timeoutSeconds":10800}}` | the maximum session sticky time if sessionAffinity is ClientIP |
| service.targetPort | int | `8080` | |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ service:
# -- Configure the liveness healthcheck for the oxshibboleth if needed.
livenessProbe:
# -- Executes the python3 healthcheck.
# https://github.com/GluuFederation/docker-oxshibboleth/blob/4.5/scripts/healthcheck.py
exec:
command:
- python3
Expand All @@ -72,7 +71,6 @@ service:
periodSeconds: 30
timeoutSeconds: 5
# -- Configure the readiness healthcheck for the oxshibboleth if needed.
# https://github.com/GluuFederation/docker-oxauth/blob/4.5/scripts/healthcheck.py
readinessProbe:
exec:
command:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,9 @@ Kubernetes: `>=v1.22.0-0`
| image.tag | string | `"4.5.5-1"` | Image tag to use for deploying. |
| lifecycle | object | `{}` | |
| livenessProbe | object | `{"exec":{"command":["python3","/app/scripts/healthcheck.py"]},"initialDelaySeconds":30,"periodSeconds":30,"timeoutSeconds":5}` | Configure the liveness healthcheck for the auth server if needed. |
| livenessProbe.exec | object | `{"command":["python3","/app/scripts/healthcheck.py"]}` | Executes the python3 healthcheck. https://github.com/GluuFederation/docker-oxauth/blob/4.3/scripts/healthcheck.py |
| livenessProbe.exec | object | `{"command":["python3","/app/scripts/healthcheck.py"]}` | Executes the python3 healthcheck. |
| nodeSelector | object | `{}` | |
| readinessProbe | object | `{"exec":{"command":["python3","/app/scripts/healthcheck.py"]},"initialDelaySeconds":25,"periodSeconds":25,"timeoutSeconds":5}` | Configure the readiness healthcheck for the auth server if needed. https://github.com/GluuFederation/docker-oxauth/blob/4.3/scripts/healthcheck.py |
| readinessProbe | object | `{"exec":{"command":["python3","/app/scripts/healthcheck.py"]},"initialDelaySeconds":25,"periodSeconds":25,"timeoutSeconds":5}` | Configure the readiness healthcheck for the auth server if needed. |
| replicas | int | `1` | Service replica number. |
| resources | object | `{"limits":{"cpu":"2500m","memory":"2500Mi"},"requests":{"cpu":"2500m","memory":"2500Mi"}}` | Resource specs. |
| resources.limits.cpu | string | `"2500m"` | CPU limit. |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@ service:
# -- Configure the liveness healthcheck for the auth server if needed.
livenessProbe:
# -- Executes the python3 healthcheck.
# https://github.com/GluuFederation/docker-oxauth/blob/4.3/scripts/healthcheck.py
exec:
command:
- python3
Expand All @@ -73,7 +72,6 @@ livenessProbe:
periodSeconds: 30
timeoutSeconds: 5
# -- Configure the readiness healthcheck for the auth server if needed.
# https://github.com/GluuFederation/docker-oxauth/blob/4.3/scripts/healthcheck.py
readinessProbe:
exec:
command:
Expand Down
Loading

0 comments on commit 3b61542

Please sign in to comment.