Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions controllers/operator/nmstate_controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -487,7 +487,7 @@ var _ = Describe("NMState controller reconcile", func() {
ds := &appsv1.DaemonSet{}
err := cl.Get(context.Background(), handlerKey, ds)
Expect(err).ToNot(HaveOccurred())
expectedCommand := "nmstatectl show -vv 2>&1"
expectedCommand := "nmstatectl show lo -vv 2>&1"
Expect(ds.Spec.Template.Spec.Containers[0].LivenessProbe.Exec.Command).To(ContainElement(expectedCommand))
})
})
Expand Down Expand Up @@ -515,7 +515,7 @@ var _ = Describe("NMState controller reconcile", func() {
ds := &appsv1.DaemonSet{}
err := cl.Get(context.Background(), handlerKey, ds)
Expect(err).ToNot(HaveOccurred())
expectedCommand := "nmstatectl show 2>&1"
expectedCommand := "nmstatectl show lo 2>&1"
Expect(ds.Spec.Template.Spec.Containers[0].LivenessProbe.Exec.Command).To(ContainElement(expectedCommand))
})
})
Expand All @@ -542,7 +542,7 @@ var _ = Describe("NMState controller reconcile", func() {
ds := &appsv1.DaemonSet{}
err := cl.Get(context.Background(), handlerKey, ds)
Expect(err).ToNot(HaveOccurred())
expectedCommand := "nmstatectl show 2>&1"
expectedCommand := "nmstatectl show lo 2>&1"
Expect(ds.Spec.Template.Spec.Containers[0].LivenessProbe.Exec.Command).To(ContainElement(expectedCommand))
})
})
Expand Down
2 changes: 1 addition & 1 deletion deploy/handler/operator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -437,7 +437,7 @@ spec:
command:
- bash
- -c
- "nmstatectl show {{ .HandlerReadinessProbeExtraArg }} 2>&1"
- "nmstatectl show lo {{ .HandlerReadinessProbeExtraArg }} 2>&1"
initialDelaySeconds: 60
periodSeconds: 60
timeoutSeconds: 10
Expand Down
8 changes: 4 additions & 4 deletions test/e2e/operator/nmstate_install_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ var _ = Describe("NMState operator", func() {
return false
}

return slices.Contains(probe.Exec.Command, "nmstatectl show -vv 2>&1")
return slices.Contains(probe.Exec.Command, "nmstatectl show lo -vv 2>&1")
}, 60*time.Second, 1*time.Second).Should(BeTrue(), "handler daemonset livenessProbe should use verbose flag")
})
AfterEach(func() {
Expand Down Expand Up @@ -247,10 +247,10 @@ var _ = Describe("NMState operator", func() {
}

for _, cmd := range probe.Exec.Command {
if cmd == "nmstatectl show -vv 2>&1" {
if cmd == "nmstatectl show lo -vv 2>&1" {
return false // Should not have verbose flag in info mode
}
if cmd == "nmstatectl show 2>&1" {
if cmd == "nmstatectl show lo 2>&1" {
return true // Should have plain nmstatectl show command
}
}
Expand Down Expand Up @@ -305,7 +305,7 @@ var _ = Describe("NMState operator", func() {
}

for _, cmd := range probe.Exec.Command {
if cmd == "nmstatectl show -vv 2>&1" {
if cmd == "nmstatectl show lo -vv 2>&1" {
return true
}
}
Expand Down