Update livness probe to check for python process
This commit is contained in:
17
values.yaml
17
values.yaml
@@ -53,25 +53,26 @@ podLabels: {} # Optional Kubernetes labels for pods
|
|||||||
podSecurityContext: {} # Pod-level security settings
|
podSecurityContext: {} # Pod-level security settings
|
||||||
securityContext: {} # Container-level security settings
|
securityContext: {} # Container-level security settings
|
||||||
|
|
||||||
# Liveness probe to check if the miner process is running
|
|
||||||
livenessProbe:
|
livenessProbe:
|
||||||
exec:
|
exec:
|
||||||
command:
|
command:
|
||||||
- /bin/sh
|
- /bin/sh
|
||||||
- -c
|
- -c
|
||||||
- "pgrep -x duino-miner > /dev/null"
|
# Check if any Python process is running (assumes your miner runs via Python)
|
||||||
initialDelaySeconds: 30 # Delay before first check
|
# If no process is found, the command exits with a non-zero code → Kubernetes marks container as unhealthy
|
||||||
periodSeconds: 60 # Check interval
|
- "pidof python > /dev/null"
|
||||||
|
initialDelaySeconds: 30 # Wait 30 seconds before first check to allow the miner to start
|
||||||
|
periodSeconds: 60 # Check every 60 seconds
|
||||||
|
|
||||||
# Readiness probe to check if the miner is ready
|
|
||||||
readinessProbe:
|
readinessProbe:
|
||||||
exec:
|
exec:
|
||||||
command:
|
command:
|
||||||
- /bin/sh
|
- /bin/sh
|
||||||
- -c
|
- -c
|
||||||
- "pgrep -x duino-miner > /dev/null"
|
# Same check as liveness: ensures a Python process is running before marking the pod ready
|
||||||
initialDelaySeconds: 10 # Delay before first check
|
- "pidof python > /dev/null"
|
||||||
periodSeconds: 30 # Check interval
|
initialDelaySeconds: 10 # Wait 10 seconds before first check to allow container startup
|
||||||
|
periodSeconds: 30 # Check every 30 seconds
|
||||||
|
|
||||||
# Volumes and mounts (if needed)
|
# Volumes and mounts (if needed)
|
||||||
volumes: [] # Define extra volumes here
|
volumes: [] # Define extra volumes here
|
||||||
|
Reference in New Issue
Block a user