Skip to content

Commit ea6af6c

Browse files
authored
fix: Add missing ReadinessProbe to Image Updater Deployment (#1923)
Signed-off-by: dkarpele <[email protected]>
1 parent a4c34db commit ea6af6c

File tree

2 files changed

+24
-0
lines changed

2 files changed

+24
-0
lines changed

controllers/argocd/image_updater.go

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -422,6 +422,18 @@ func (r *ReconcileArgoCD) reconcileImageUpdaterDeployment(cr *argoproj.ArgoCD, s
422422
InitialDelaySeconds: 15,
423423
PeriodSeconds: 20,
424424
},
425+
ReadinessProbe: &corev1.Probe{
426+
ProbeHandler: corev1.ProbeHandler{
427+
HTTPGet: &corev1.HTTPGetAction{
428+
Path: "/readyz",
429+
Port: intstr.IntOrString{
430+
IntVal: int32(8081),
431+
},
432+
},
433+
},
434+
InitialDelaySeconds: 5,
435+
PeriodSeconds: 10,
436+
},
425437
SecurityContext: argoutil.DefaultSecurityContext(),
426438
VolumeMounts: []corev1.VolumeMount{
427439
{

controllers/argocd/image_updater_test.go

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -292,6 +292,18 @@ func TestReconcileImageUpdater_CreateDeployments(t *testing.T) {
292292
InitialDelaySeconds: 15,
293293
PeriodSeconds: 20,
294294
},
295+
ReadinessProbe: &v1.Probe{
296+
ProbeHandler: v1.ProbeHandler{
297+
HTTPGet: &v1.HTTPGetAction{
298+
Path: "/readyz",
299+
Port: intstr.IntOrString{
300+
IntVal: int32(8081),
301+
},
302+
},
303+
},
304+
InitialDelaySeconds: 5,
305+
PeriodSeconds: 10,
306+
},
295307
}}
296308

297309
if diff := cmp.Diff(want, deployment.Spec.Template.Spec.Containers); diff != "" {

0 commit comments

Comments
 (0)