chore(deps): update all major dependencies (master) (major) #1519
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: e2e-test | |
| on: | |
| push: | |
| branches: | |
| - master | |
| pull_request: | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| env: | |
| REPOSITORY: koperator_e2e_test | |
| jobs: | |
| build: | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v7 | |
| - name: Clean workspace | |
| run: | | |
| # Remove any existing go.work files to ensure clean module resolution | |
| rm -f go.work go.work.sum | |
| - name: Set up Go | |
| uses: actions/setup-go@v7 | |
| with: | |
| go-version-file: go.mod | |
| - name: Setup Helm | |
| uses: azure/setup-helm@v5 | |
| with: | |
| version: '4.2.3' | |
| - name: Clean Go module cache | |
| run: | | |
| # Clean any existing Go module cache to avoid conflicts | |
| # Use sudo to handle permission issues and force removal | |
| sudo rm -rf ~/go/pkg/mod || true | |
| sudo rm -rf ~/.cache/go-build || true | |
| mkdir -p ~/go/pkg/mod | |
| mkdir -p ~/.cache/go-build | |
| # Ensure proper permissions | |
| chmod -R 755 ~/go/pkg/mod | |
| chmod -R 755 ~/.cache/go-build | |
| # Enable Tmate Session to debug the E2E Kind Cluster | |
| # Only activates when re-running the workflow in debug mode | |
| - name: Setup tmate session | |
| if: ${{ runner.debug == '1' }} | |
| continue-on-error: true | |
| uses: mxschmitt/action-tmate@v3 | |
| with: | |
| detached: true | |
| limit-access-to-actor: true | |
| - name: Build docker image | |
| run: | | |
| IMG=$REPOSITORY:$GITHUB_SHA make docker-build | |
| - name: Setup Kind cluster | |
| id: setup-kind | |
| uses: ./.github/actions/kind-create | |
| - name: Load image into kind cluster | |
| run: | | |
| kind load docker-image $REPOSITORY:$GITHUB_SHA --name e2e-kind | |
| - name: Download dependencies | |
| run: | | |
| # Download dependencies for all modules | |
| go mod download | |
| cd api && go mod download && cd .. | |
| cd properties && go mod download && cd .. | |
| cd tests/e2e && go mod download && cd ../.. | |
| - name: Run E2E tests | |
| env: | |
| KUBECONFIG: ${{ steps.setup-kind.outputs.kubeconfig }} | |
| run: | | |
| # Clean any existing go.work files to avoid workspace conflicts | |
| rm -f go.work go.work.sum | |
| IMG_E2E=$REPOSITORY:$GITHUB_SHA make test-e2e | |
| # Dump cluster diagnostics on failure so e2e failures (e.g. a dependency Helm | |
| # install that times out under `--atomic`) are debuggable from the job log | |
| # without needing a live tmate session. | |
| - name: Dump diagnostics on failure | |
| if: failure() | |
| env: | |
| KUBECONFIG: ${{ steps.setup-kind.outputs.kubeconfig }} | |
| run: | | |
| set +e | |
| echo "::group::nodes" | |
| kubectl get nodes -o wide | |
| echo "::endgroup::" | |
| echo "::group::all pods" | |
| kubectl get pods -A -o wide | |
| echo "::endgroup::" | |
| for ns in cert-manager projectcontour zookeeper prometheus kafka; do | |
| echo "::group::namespace ${ns}" | |
| kubectl get pods -n "${ns}" -o wide | |
| echo "----- events (${ns}) -----" | |
| kubectl get events -n "${ns}" --sort-by=.lastTimestamp | tail -50 | |
| echo "----- describe pods (${ns}) -----" | |
| kubectl describe pods -n "${ns}" | |
| echo "----- container logs (${ns}) -----" | |
| for pod in $(kubectl get pods -n "${ns}" -o name); do | |
| echo ">>> ${pod} (current) <<<" | |
| kubectl logs -n "${ns}" "${pod}" --all-containers --tail=150 --timestamps | |
| echo ">>> ${pod} (previous, if the container restarted) <<<" | |
| kubectl logs -n "${ns}" "${pod}" --all-containers --previous --tail=150 --timestamps | |
| done | |
| echo "::endgroup::" | |
| done | |
| echo "::group::warning events (all namespaces)" | |
| kubectl get events -A --field-selector type=Warning --sort-by=.lastTimestamp | tail -80 | |
| echo "::endgroup::" | |
| exit 0 |