Skip to content

Commit

Permalink
chore(ci): Wait for operator pod to start
Browse files Browse the repository at this point in the history
Stabilize the CI workflow and avoid errors due to tests running before operator has completely started
  • Loading branch information
christophd committed Aug 28, 2023
1 parent cc99478 commit 378db2f
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .github/workflows/kubernetes.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ jobs:
KNATIVE_SERVING_VERSION: v1.9.4
KNATIVE_EVENTING_VERSION: v1.9.7
KNATIVE_KOURIER_VERSION: v1.9.2
KUBECTL_WAIT_TIMEOUT: "180s"
steps:
- name: Checkout code
uses: actions/checkout@v3
Expand Down Expand Up @@ -96,13 +97,19 @@ jobs:
export KAMEL_INSTALL_REGISTRY_INSECURE=true
kamel install
# Wait for operator to start
kubectl wait pod -l app=camel-k --for condition=Ready --timeout=${{ env.KUBECTL_WAIT_TIMEOUT }}
- name: YAKS tools
uses: citrusframework/[email protected]
with:
version: v${{ env.YAKS_VERSION }}
- name: Install YAKS
run: |
yaks install --operator-image $YAKS_IMAGE_NAME:$YAKS_VERSION
# Wait for operator to start
kubectl wait pod -l app=yaks --for condition=Ready --timeout=${{ env.KUBECTL_WAIT_TIMEOUT }}
- name: YAKS Tests
run: |
# Then run integration tests
Expand Down
14 changes: 14 additions & 0 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ jobs:
KNATIVE_SERVING_VERSION: v1.9.4
KNATIVE_EVENTING_VERSION: v1.9.7
KNATIVE_KOURIER_VERSION: v1.9.2
KUBECTL_WAIT_TIMEOUT: "180s"
steps:
- name: Checkout code
uses: actions/checkout@v3
Expand Down Expand Up @@ -90,13 +91,19 @@ jobs:
export KAMEL_INSTALL_REGISTRY_INSECURE=true
kamel install --maven-repository=https://repository.apache.org/content/repositories/snapshots@id=apache-snapshots@snapshots
# Wait for operator to start
kubectl wait pod -l app=camel-k --for condition=Ready --timeout=${{ env.KUBECTL_WAIT_TIMEOUT }}
- name: YAKS tools
uses: citrusframework/[email protected]
with:
version: v${{ env.YAKS_VERSION }}
- name: Install YAKS
run: |
yaks install --operator-image $YAKS_IMAGE_NAME:$YAKS_VERSION
# Wait for operator to start
kubectl wait pod -l app=yaks --for condition=Ready --timeout=${{ env.KUBECTL_WAIT_TIMEOUT }}
- name: YAKS Tests
run: |
# Then run integration tests
Expand Down Expand Up @@ -126,6 +133,7 @@ jobs:
KNATIVE_SERVING_VERSION: v1.9.4
KNATIVE_EVENTING_VERSION: v1.9.7
KNATIVE_KOURIER_VERSION: v1.9.2
KUBECTL_WAIT_TIMEOUT: "180s"
steps:
- name: Checkout code
uses: actions/checkout@v3
Expand Down Expand Up @@ -180,13 +188,19 @@ jobs:
export KAMEL_INSTALL_REGISTRY_INSECURE=true
kamel install
# Wait for operator to start
kubectl wait pod -l app=camel-k --for condition=Ready --timeout=${{ env.KUBECTL_WAIT_TIMEOUT }}
- name: YAKS tools
uses: citrusframework/[email protected]
with:
version: v${{ env.YAKS_VERSION }}
- name: Install YAKS
run: |
yaks install --operator-image $YAKS_IMAGE_NAME:$YAKS_VERSION
# Wait for operator to start
kubectl wait pod -l app=yaks --for condition=Ready --timeout=${{ env.KUBECTL_WAIT_TIMEOUT }}
- name: YAKS Tests
run: |
# Then run integration tests
Expand Down

0 comments on commit 378db2f

Please sign in to comment.