Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

E2E: make sure frr-k8s-webhook pod is Ready #493

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

karampok
Copy link

@karampok karampok commented Sep 19, 2024

Frr-k8s-webhook is crashes at least 3 times and then it becomes ready, but sometimes it remains crashing.

Current check is checking if pod is Running but this is not enough

   containerStatuses:
    - containerID: containerd://fe46fd402ccb0ea512037e4fbc3c12c90de7c7e40ed4adb0ee5c51681f89b8d7
      image: quay.io/metallb/frr-k8s:v0.0.14
      imageID: quay.io/metallb/frr-k8s@sha256:00f8c40129fb1403760d2e846fc970dc11ca8d19068f012a26f2b683f98cb598
      lastState:
        terminated:
          containerID: containerd://22f5f5ccbe3832019b15460f5a6947ce22bba838bc45cbaa6c60b0c0f94b4aaf
          exitCode: 0
          finishedAt: "2024-09-19T08:11:19Z"
          reason: Completed
          startedAt: "2024-09-19T08:11:18Z"
      name: frr-k8s-webhook-server
      ready: false
      restartCount: 1
      started: false
      state:
        terminated:
          containerID: containerd://fe46fd402ccb0ea512037e4fbc3c12c90de7c7e40ed4adb0ee5c51681f89b8d7
          exitCode: 1
          finishedAt: "2024-09-19T08:11:21Z"
          reason: Error
          startedAt: "2024-09-19T08:11:20Z"
    hostIP: 172.18.0.3
    hostIPs:
    - ip: 172.18.0.3
    phase: Running
 k -n metallb-system get pods -l  component=frr-k8s-webhook-server -o wide -w
NAME                                      READY   STATUS    RESTARTS   AGE   IP       NODE     NOMINATED NODE   READINESS GATES
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     Pending   0          0s    <none>   <none>   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     Pending   0          0s    <none>   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     ContainerCreating   0          0s    <none>   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     Running             0          0s    10.244.2.11   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     Completed           0          1s    10.244.2.11   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     Running             1 (2s ago)   3s    10.244.2.11   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     Error               1 (4s ago)   5s    10.244.2.11   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     CrashLoopBackOff    1 (7s ago)   10s   10.244.2.11   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     Running             2 (23s ago)   26s   10.244.2.11   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     Completed           2 (24s ago)   27s   10.244.2.11   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     CrashLoopBackOff    2 (2s ago)    28s   10.244.2.11   kind-worker   <none>           <none>

frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     Running             3 (35s ago)   61s   10.244.2.11   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   1/1     Running             3 (44s ago)   70s   10.244.2.11   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   1/1     Terminating         3 (76s ago)   102s   10.244.2.11   kind-worker   <none>           <none>

Is this a BUG FIX or a FEATURE ?:

/kind failing

What this PR does / why we need it:

Special notes for your reviewer:

Release note:



},
Entry("Native Mode", metallbv1beta1.NativeMode),
Entry("FRR Mode", metallbv1beta1.FRRMode),
Entry("FRR-K8s Mode", metallbv1beta1.FRRK8sMode),
FEntry("FRR-K8s Mode", metallbv1beta1.FRRK8sMode),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

leftover?

@@ -280,7 +280,7 @@ var _ = Describe("metallb", func() {
}, metallbutils.DeployTimeout, metallbutils.Interval).ShouldNot(HaveOccurred())

By("checking frr-k8s webhook deployment is in running state")
Eventually(func() error {
c := func() error {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's give this a proper name

@karampok karampok force-pushed the webhook-issue branch 2 times, most recently from 67bd35c to 200ca88 Compare September 19, 2024 09:17
Frr-k8s-webhook is crashes at least 3 times and then it becomes ready,
but sometimes it remains crashing.

Current check is checking if pod is Running but this is not enough
```
   containerStatuses:
    - containerID: containerd://fe46fd402ccb0ea512037e4fbc3c12c90de7c7e40ed4adb0ee5c51681f89b8d7
      image: quay.io/metallb/frr-k8s:v0.0.14
      imageID: quay.io/metallb/frr-k8s@sha256:00f8c40129fb1403760d2e846fc970dc11ca8d19068f012a26f2b683f98cb598
      lastState:
        terminated:
          containerID: containerd://22f5f5ccbe3832019b15460f5a6947ce22bba838bc45cbaa6c60b0c0f94b4aaf
          exitCode: 0
          finishedAt: "2024-09-19T08:11:19Z"
          reason: Completed
          startedAt: "2024-09-19T08:11:18Z"
      name: frr-k8s-webhook-server
      ready: false
      restartCount: 1
      started: false
      state:
        terminated:
          containerID: containerd://fe46fd402ccb0ea512037e4fbc3c12c90de7c7e40ed4adb0ee5c51681f89b8d7
          exitCode: 1
          finishedAt: "2024-09-19T08:11:21Z"
          reason: Error
          startedAt: "2024-09-19T08:11:20Z"
    hostIP: 172.18.0.3
    hostIPs:
    - ip: 172.18.0.3
    phase: Running
```

```
 k -n metallb-system get pods -l  component=frr-k8s-webhook-server -o wide -w
NAME                                      READY   STATUS    RESTARTS   AGE   IP       NODE     NOMINATED NODE   READINESS GATES
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     Pending   0          0s    <none>   <none>   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     Pending   0          0s    <none>   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     ContainerCreating   0          0s    <none>   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     Running             0          0s    10.244.2.11   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     Completed           0          1s    10.244.2.11   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     Running             1 (2s ago)   3s    10.244.2.11   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     Error               1 (4s ago)   5s    10.244.2.11   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     CrashLoopBackOff    1 (7s ago)   10s   10.244.2.11   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     Running             2 (23s ago)   26s   10.244.2.11   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     Completed           2 (24s ago)   27s   10.244.2.11   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     CrashLoopBackOff    2 (2s ago)    28s   10.244.2.11   kind-worker   <none>           <none>

frr-k8s-webhook-server-6ffd7bc857-glnvr   0/1     Running             3 (35s ago)   61s   10.244.2.11   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   1/1     Running             3 (44s ago)   70s   10.244.2.11   kind-worker   <none>           <none>
frr-k8s-webhook-server-6ffd7bc857-glnvr   1/1     Terminating         3 (76s ago)   102s   10.244.2.11   kind-worker   <none>           <none>
```

Signed-off-by: karampok <[email protected]>
otherwise it fails with
```
Error: This request has been automatically failed because it uses a deprecated version of `actions/upload-artifact: v2`. Learn more: https://github.blog/changelog/2024-02-13-deprecation-notice-v1-and-v2-of-the-artifact-actions/
```

and some changes to make yaml linter quiet.

Signed-off-by: karampok <[email protected]>
@karampok
Copy link
Author

@fedepaol should we merge that?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants