Adds startupProbe to prometheus-adapter (#2029)
Issue: https://issues.redhat.com/browse/OCPBUGS-7694 Problem: in clusters with a large nb of CRDs deployed prom-adapter takes too long to discover all of them which makes it fail the livenessProbe Solution: introduce a startupProbe that gives 3 minutes for prom-adapter to initialize Signed-off-by: JoaoBraveCoding <jmarcal@redhat.com>
This commit is contained in:
@@ -236,13 +236,21 @@ function(params) {
|
|||||||
'--tls-cipher-suites=' + std.join(',', pa._config.tlsCipherSuites),
|
'--tls-cipher-suites=' + std.join(',', pa._config.tlsCipherSuites),
|
||||||
],
|
],
|
||||||
resources: pa._config.resources,
|
resources: pa._config.resources,
|
||||||
|
startupProbe: {
|
||||||
|
httpGet: {
|
||||||
|
path: '/livez',
|
||||||
|
port: 'https',
|
||||||
|
scheme: 'HTTPS',
|
||||||
|
},
|
||||||
|
periodSeconds: 10,
|
||||||
|
failureThreshold: 18,
|
||||||
|
},
|
||||||
readinessProbe: {
|
readinessProbe: {
|
||||||
httpGet: {
|
httpGet: {
|
||||||
path: '/readyz',
|
path: '/readyz',
|
||||||
port: 'https',
|
port: 'https',
|
||||||
scheme: 'HTTPS',
|
scheme: 'HTTPS',
|
||||||
},
|
},
|
||||||
initialDelaySeconds: 30,
|
|
||||||
periodSeconds: 5,
|
periodSeconds: 5,
|
||||||
failureThreshold: 5,
|
failureThreshold: 5,
|
||||||
},
|
},
|
||||||
@@ -252,7 +260,6 @@ function(params) {
|
|||||||
port: 'https',
|
port: 'https',
|
||||||
scheme: 'HTTPS',
|
scheme: 'HTTPS',
|
||||||
},
|
},
|
||||||
initialDelaySeconds: 30,
|
|
||||||
periodSeconds: 5,
|
periodSeconds: 5,
|
||||||
failureThreshold: 5,
|
failureThreshold: 5,
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -44,7 +44,6 @@ spec:
|
|||||||
path: /livez
|
path: /livez
|
||||||
port: https
|
port: https
|
||||||
scheme: HTTPS
|
scheme: HTTPS
|
||||||
initialDelaySeconds: 30
|
|
||||||
periodSeconds: 5
|
periodSeconds: 5
|
||||||
name: prometheus-adapter
|
name: prometheus-adapter
|
||||||
ports:
|
ports:
|
||||||
@@ -56,7 +55,6 @@ spec:
|
|||||||
path: /readyz
|
path: /readyz
|
||||||
port: https
|
port: https
|
||||||
scheme: HTTPS
|
scheme: HTTPS
|
||||||
initialDelaySeconds: 30
|
|
||||||
periodSeconds: 5
|
periodSeconds: 5
|
||||||
resources:
|
resources:
|
||||||
limits:
|
limits:
|
||||||
@@ -71,6 +69,13 @@ spec:
|
|||||||
drop:
|
drop:
|
||||||
- ALL
|
- ALL
|
||||||
readOnlyRootFilesystem: true
|
readOnlyRootFilesystem: true
|
||||||
|
startupProbe:
|
||||||
|
failureThreshold: 18
|
||||||
|
httpGet:
|
||||||
|
path: /livez
|
||||||
|
port: https
|
||||||
|
scheme: HTTPS
|
||||||
|
periodSeconds: 10
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
- mountPath: /tmp
|
- mountPath: /tmp
|
||||||
name: tmpfs
|
name: tmpfs
|
||||||
|
|||||||
Reference in New Issue
Block a user