1
0
Fork 0
mirror of https://github.com/kubernetes-sigs/node-feature-discovery.git synced 2025-03-20 07:12:43 +00:00
node-feature-discovery/deployment/base/master/master-deployment.yaml
Markus Lehtonen fb6484fb8d deployment: add startupProbe for nfd-master
This patch mitigates inadvertent termination of nfd-master pods by the
liveness probe on big clusters.

With a recent change nfd-master started to wait (block) for informer
caches to sync before starting the main loop. Consequently, this change
also made the gRPC health enpoint to not respond until the caches have
been synced. In big clusters the syncing the NodeFeature object cache
takes a long time as the objects are big and there's (at least) one per
each node in the cluster. Thus, in big clusters, the liveness probe
kicks in and kills the nfd-master pod before it's ready.
2024-12-12 20:00:49 +02:00

46 lines
1 KiB
YAML

apiVersion: apps/v1
kind: Deployment
metadata:
labels:
app: nfd
name: nfd-master
spec:
replicas: 1
selector:
matchLabels:
app: nfd-master
template:
metadata:
labels:
app: nfd-master
spec:
serviceAccount: nfd-master
enableServiceLinks: false
tolerations: []
containers:
- name: nfd-master
image: gcr.io/k8s-staging-nfd/node-feature-discovery:master
imagePullPolicy: Always
resources:
limits:
cpu: 300m
memory: 4Gi
requests:
cpu: 100m
memory: 128Mi
startupProbe:
grpc:
port: 8082
failureThreshold: 30
livenessProbe:
grpc:
port: 8082
readinessProbe:
grpc:
port: 8082
failureThreshold: 10
command:
- "nfd-master"
ports:
- name: metrics
containerPort: 8081