Skip to content

Commit

Permalink
ci: Wait for hubble-relay to be ready before port-forward
Browse files Browse the repository at this point in the history
This commit adds calls to `cilium status --wait` between places where
hubble is enabled and hubble-relay is port forwarded. Flakes in CI were
occurring due to a race conditition, where an attempt to forward the
hubble-relay port was occurring before the hubble-relay pod was ready.

Related: cilium/cilium-cli#986

Fixes: #25560

Signed-off-by: Ryan Drew <ryan.drew@isovalent.com>
  • Loading branch information
learnitall authored and aspsk committed Jun 8, 2023
1 parent 6b8adac commit 9a47a49
Show file tree
Hide file tree
Showing 8 changed files with 48 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .github/workflows/conformance-aks-v1.11.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -264,6 +264,10 @@ jobs:
run: |
cilium hubble enable ${{ steps.vars.outputs.hubble_enable_defaults }}
- name: Wait for Cilium status to be ready
run: |
cilium status --wait
- name: Port forward Relay
run: |
cilium hubble port-forward&
Expand Down Expand Up @@ -297,6 +301,10 @@ jobs:
run: |
cilium hubble enable ${{ steps.vars.outputs.hubble_enable_defaults }}
- name: Wait for Cilium status to be ready
run: |
cilium status --wait
- name: Port forward Relay
run: |
cilium hubble port-forward&
Expand Down
8 changes: 8 additions & 0 deletions .github/workflows/conformance-aks-v1.12.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -266,6 +266,10 @@ jobs:
run: |
cilium hubble enable ${{ steps.vars.outputs.hubble_enable_defaults }}
- name: Wait for Cilium status to be ready
run: |
cilium status --wait
- name: Port forward Relay
run: |
cilium hubble port-forward&
Expand Down Expand Up @@ -299,6 +303,10 @@ jobs:
run: |
cilium hubble enable ${{ steps.vars.outputs.hubble_enable_defaults }}
- name: Wait for Cilium status to be ready
run: |
cilium status --wait
- name: Port forward Relay
run: |
cilium hubble port-forward&
Expand Down
8 changes: 8 additions & 0 deletions .github/workflows/conformance-aks-v1.13.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -266,6 +266,10 @@ jobs:
run: |
cilium hubble enable ${{ steps.vars.outputs.hubble_enable_defaults }}
- name: Wait for Cilium status to be ready
run: |
cilium status --wait
- name: Port forward Relay
run: |
cilium hubble port-forward&
Expand Down Expand Up @@ -299,6 +303,10 @@ jobs:
run: |
cilium hubble enable ${{ steps.vars.outputs.hubble_enable_defaults }}
- name: Wait for Cilium status to be ready
run: |
cilium status --wait
- name: Port forward Relay
run: |
cilium hubble port-forward&
Expand Down
8 changes: 8 additions & 0 deletions .github/workflows/conformance-aks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -262,6 +262,10 @@ jobs:
run: |
cilium hubble enable ${{ steps.vars.outputs.hubble_enable_defaults }}
- name: Wait for Cilium status to be ready
run: |
cilium status --wait
- name: Port forward Relay
run: |
cilium hubble port-forward&
Expand Down Expand Up @@ -295,6 +299,10 @@ jobs:
run: |
cilium hubble enable ${{ steps.vars.outputs.hubble_enable_defaults }}
- name: Wait for Cilium status to be ready
run: |
cilium status --wait
- name: Port forward Relay
run: |
cilium hubble port-forward&
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/conformance-gke-v1.11.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -317,6 +317,10 @@ jobs:
run: |
cilium hubble enable ${{ steps.vars.outputs.hubble_enable_defaults }}
- name: Wait for Cilium status to be ready
run: |
cilium status --wait
- name: Port forward Relay
run: |
cilium hubble port-forward&
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/conformance-gke-v1.12.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -317,6 +317,10 @@ jobs:
run: |
cilium hubble enable ${{ steps.vars.outputs.hubble_enable_defaults }}
- name: Wait for Cilium status to be ready
run: |
cilium status --wait
- name: Port forward Relay
run: |
cilium hubble port-forward&
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/conformance-gke-v1.13.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -318,6 +318,10 @@ jobs:
run: |
cilium hubble enable ${{ steps.vars.outputs.hubble_enable_defaults }}
- name: Wait for Cilium status to be ready
run: |
cilium status --wait
- name: Port forward Relay
run: |
cilium hubble port-forward&
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/conformance-gke.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -314,6 +314,10 @@ jobs:
cilium status --wait
kubectl get pods -n kube-system
- name: Wait for Cilium status to be ready
run: |
cilium status --wait
- name: Port forward Relay
run: |
cilium hubble port-forward&
Expand Down

0 comments on commit 9a47a49

Please sign in to comment.