diff --git a/.github/workflows/e2e-elasticsearch.yaml b/.github/workflows/e2e-elasticsearch.yaml deleted file mode 100644 index a7bd670028..0000000000 --- a/.github/workflows/e2e-elasticsearch.yaml +++ /dev/null @@ -1,34 +0,0 @@ -name: Elasticsearch E2E tests - -on: - push: - branches: [ main ] - paths-ignore: - - '**.md' - pull_request: - branches: [ main ] - paths-ignore: - - '**.md' - -concurrency: - group: e2e-tests-${{ github.ref }}-${{ github.workflow }} - cancel-in-progress: true - -jobs: - run-e2e-elasticsearch-test-suite: - runs-on: ubuntu-20.04 - strategy: - matrix: - kube-version: - - "1.19" - - "1.28" - name: Run Elasticsearch E2E tests - steps: - - name: "Check out code into the Go module directory" - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - uses: ./hack/actions/e2e - with: - testsuite_name: elasticsearch - kube_version: ${{ matrix.kube-version }} diff --git a/.github/workflows/e2e-examples.yaml b/.github/workflows/e2e-examples.yaml deleted file mode 100644 index 8cd6d5acd1..0000000000 --- a/.github/workflows/e2e-examples.yaml +++ /dev/null @@ -1,34 +0,0 @@ -name: Examples E2E tests - -on: - push: - branches: [ main ] - paths-ignore: - - '**.md' - pull_request: - branches: [ main ] - paths-ignore: - - '**.md' - -concurrency: - group: e2e-tests-${{ github.ref }}-${{ github.workflow }} - cancel-in-progress: true - -jobs: - run-e2e-examples-test-suite: - runs-on: ubuntu-20.04 - strategy: - matrix: - kube-version: - - "1.19" - - "1.28" - name: Run examples E2E tests - steps: - - name: "Check out code into the Go module directory" - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - uses: ./hack/actions/e2e - with: - testsuite_name: examples - kube_version: ${{ matrix.kube-version }} diff --git a/.github/workflows/e2e-generate.yaml b/.github/workflows/e2e-generate.yaml deleted file mode 100644 index 778e7f160d..0000000000 --- a/.github/workflows/e2e-generate.yaml +++ /dev/null @@ -1,34 +0,0 @@ -name: Generate E2E tests - -on: - push: - branches: [ main ] - paths-ignore: - - '**.md' - pull_request: - branches: [ main ] - paths-ignore: - - '**.md' - -concurrency: - group: e2e-tests-${{ github.ref }}-${{ github.workflow }} - cancel-in-progress: true - -jobs: - run-e2e-generate-test-suite: - runs-on: ubuntu-20.04 - strategy: - matrix: - kube-version: - - "1.19" - - "1.28" - name: Run generate E2E tests - steps: - - name: "Check out code into the Go module directory" - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - uses: ./hack/actions/e2e - with: - testsuite_name: generate - kube_version: ${{ matrix.kube-version }} diff --git a/.github/workflows/e2e-miscellaneous.yaml b/.github/workflows/e2e-miscellaneous.yaml deleted file mode 100644 index 9c5da3ca66..0000000000 --- a/.github/workflows/e2e-miscellaneous.yaml +++ /dev/null @@ -1,34 +0,0 @@ -name: Miscellaneous E2E tests - -on: - push: - branches: [ main ] - paths-ignore: - - '**.md' - pull_request: - branches: [ main ] - paths-ignore: - - '**.md' - -concurrency: - group: e2e-tests-${{ github.ref }}-${{ github.workflow }} - cancel-in-progress: true - -jobs: - run-e2e-miscellaneous-test-suite: - runs-on: ubuntu-20.04 - strategy: - matrix: - kube-version: - - "1.19" - - "1.28" - name: Run miscellaneous E2E tests - steps: - - name: "Check out code into the Go module directory" - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - uses: ./hack/actions/e2e - with: - testsuite_name: miscellaneous - kube_version: ${{ matrix.kube-version }} diff --git a/.github/workflows/e2e-sidecar.yaml b/.github/workflows/e2e-sidecar.yaml deleted file mode 100644 index 3ca9a9de0c..0000000000 --- a/.github/workflows/e2e-sidecar.yaml +++ /dev/null @@ -1,34 +0,0 @@ -name: Sidecar E2E tests - -on: - push: - branches: [ main ] - paths-ignore: - - '**.md' - pull_request: - branches: [ main ] - paths-ignore: - - '**.md' - -concurrency: - group: e2e-tests-${{ github.ref }}-${{ github.workflow }} - cancel-in-progress: true - -jobs: - run-e2e-sidecar-test-suite: - runs-on: ubuntu-20.04 - strategy: - matrix: - kube-version: - - "1.19" - - "1.28" - name: Run sidecar E2E tests - steps: - - name: "Check out code into the Go module directory" - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - uses: ./hack/actions/e2e - with: - testsuite_name: sidecar - kube_version: ${{ matrix.kube-version }} diff --git a/.github/workflows/e2e-streaming.yaml b/.github/workflows/e2e-streaming.yaml deleted file mode 100644 index c50be0e038..0000000000 --- a/.github/workflows/e2e-streaming.yaml +++ /dev/null @@ -1,34 +0,0 @@ -name: Streaming E2E tests - -on: - push: - branches: [ main ] - paths-ignore: - - '**.md' - pull_request: - branches: [ main ] - paths-ignore: - - '**.md' - -concurrency: - group: e2e-tests-${{ github.ref }}-${{ github.workflow }} - cancel-in-progress: true - -jobs: - run-e2e-streaming-test-suite: - runs-on: ubuntu-20.04 - strategy: - matrix: - kube-version: - - "1.19" - - "1.28" - name: Run streaming E2E tests - steps: - - name: "Check out code into the Go module directory" - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - uses: ./hack/actions/e2e - with: - testsuite_name: streaming - kube_version: ${{ matrix.kube-version }} diff --git a/.github/workflows/e2e-ui.yaml b/.github/workflows/e2e-ui.yaml deleted file mode 100644 index 6b3cb28f25..0000000000 --- a/.github/workflows/e2e-ui.yaml +++ /dev/null @@ -1,34 +0,0 @@ -name: UI E2E tests - -on: - push: - branches: [ main ] - paths-ignore: - - '**.md' - pull_request: - branches: [ main ] - paths-ignore: - - '**.md' - -concurrency: - group: e2e-tests-${{ github.ref }}-${{ github.workflow }} - cancel-in-progress: true - -jobs: - run-e2e-allinone-test-suite: - runs-on: ubuntu-20.04 - strategy: - matrix: - kube-version: - - "1.19" - - "1.28" - name: UI E2E tests - steps: - - name: "Check out code into the Go module directory" - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - uses: ./hack/actions/e2e - with: - testsuite_name: ui - kube_version: ${{ matrix.kube-version }} diff --git a/.github/workflows/e2e-upgrade.yaml b/.github/workflows/e2e-upgrade.yaml deleted file mode 100644 index 12a5a90a9d..0000000000 --- a/.github/workflows/e2e-upgrade.yaml +++ /dev/null @@ -1,34 +0,0 @@ -name: Upgrade E2E tests - -on: - push: - branches: [ main ] - paths-ignore: - - '**.md' - pull_request: - branches: [ main ] - paths-ignore: - - '**.md' - -concurrency: - group: e2e-tests-${{ github.ref }}-${{ github.workflow }} - cancel-in-progress: true - -jobs: - run-e2e-upgrade-test-suite: - runs-on: ubuntu-20.04 - strategy: - matrix: - kube-version: - - "1.19" - - "1.28" - name: Run upgrade E2E tests - steps: - - name: "Check out code into the Go module directory" - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - uses: ./hack/actions/e2e - with: - testsuite_name: upgrade - kube_version: ${{ matrix.kube-version }} diff --git a/.github/workflows/e2e.yaml b/.github/workflows/e2e.yaml new file mode 100644 index 0000000000..0530b95a9c --- /dev/null +++ b/.github/workflows/e2e.yaml @@ -0,0 +1,81 @@ +name: Run E2E tests + +on: + push: + branches: [ main ] + paths-ignore: + - '**.md' + pull_request: + branches: [ main ] + paths-ignore: + - '**.md' +concurrency: + group: e2e-tests-${{ github.ref }}-${{ github.workflow }} + cancel-in-progress: true + +jobs: + e2e: + name: "Run ${{ matrix.testsuite.label }} E2E test suite on Kube ${{ matrix.kube-version }}" + runs-on: ubuntu-20.04 + strategy: + fail-fast: false + matrix: + kube-version: + - "1.19" + - "1.28" + testsuite: + - { name: "elasticsearch", label: "Elasticsearch" } + - { name: "examples", label: "Examples" } + - { name: "generate", label: "Generate" } + - { name: "miscellaneous", label: "Miscellaneous" } + - { name: "sidecar", label: "Sidecar" } + - { name: "streaming", label: "Streaming" } + - { name: "ui", label: "UI" } + - { name: "upgrade", label: "Upgrade" } + steps: + - name: "Check out code into the Go module directory" + uses: actions/checkout@v4 + with: + fetch-depth: 0 + - name: "Set up Go" + uses: actions/setup-go@v5 + with: + go-version: "1.21" + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + with: + install: true + - name: Cache Docker layers + uses: actions/cache@v3 + with: + path: /tmp/.buildx-cache + key: e2e-${{ github.sha }} + restore-keys: | + e2e- + - name: "Install KIND" + run: ./hack/install/install-kind.sh + shell: bash + - name: "Install KUTTL" + run: ./hack/install/install-kuttl.sh + shell: bash + - name: "Install gomplate" + run: ./hack/install/install-gomplate.sh + shell: bash + - name: "Install dependencies" + run: make install-tools + shell: bash + - name: "Run ${{ matrix.testsuite.label }} E2E test suite on Kube ${{ matrix.kube-version }}" + env: + VERBOSE: "true" + KUBE_VERSION: "${{ matrix.kube-version }}" + DOCKER_BUILD_OPTIONS: "--cache-from type=local,src=/tmp/.buildx-cache --cache-to type=local,dest=/tmp/.buildx-cache-new,mode=max --load" + run: make run-e2e-tests-${{ matrix.testsuite.name }} + shell: bash + # Temp fix + # https://github.com/docker/build-push-action/issues/252 + # https://github.com/moby/buildkit/issues/1896 + - name: Move cache + run: | + rm -rf /tmp/.buildx-cache + mv /tmp/.buildx-cache-new /tmp/.buildx-cache + shell: bash diff --git a/hack/actions/e2e/action.yaml b/hack/actions/e2e/action.yaml deleted file mode 100644 index 5b27346e8d..0000000000 --- a/hack/actions/e2e/action.yaml +++ /dev/null @@ -1,66 +0,0 @@ -# GitHub action to run the E2E tests. -# For this purpose, it would be a better idea to use a reusable workflow. There -# is some documentation about how to use a local reusable workflow: -# https://github.blog/changelog/2022-01-25-github-actions-reusable-workflows-can-be-referenced-locally/ -# But it seems it doesn't work properly: -# https://github.community/t/allow-reusable-workflows-to-be-located-at-arbitrary-locations-and-be-local/212745/7 -# So, the CI uses a local GitHub action as a template to run all the tests. -name: Run E2E tests -description: "Run an E2E test suite" - -inputs: - testsuite_name: - description: "Name of the test suite to run" - required: true - kube_version: - description: "Kubernetes version to use" - required: true - - -runs: - using: "composite" - steps: - - name: "Set up Go" - uses: actions/setup-go@v2.1.4 - with: - go-version: "1.21" - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v1 - with: - install: true - - - name: Cache Docker layers - uses: actions/cache@v2 - with: - path: /tmp/.buildx-cache - key: e2e-${{ github.sha }} - restore-keys: | - e2e- - - name: "Install KIND" - run: ./hack/install/install-kind.sh - shell: bash - - name: "Install KUTTL" - run: ./hack/install/install-kuttl.sh - shell: bash - - name: "Install gomplate" - run: ./hack/install/install-gomplate.sh - shell: bash - - name: "Install dependencies" - run: make install-tools - shell: bash - - name: "Run E2E ${{ inputs.testsuite_name }} test suite on ${{ inputs.kube_version }}" - env: - VERBOSE: "true" - KUBE_VERSION: "${{ inputs.kube_version }}" - DOCKER_BUILD_OPTIONS: "--cache-from type=local,src=/tmp/.buildx-cache --cache-to type=local,dest=/tmp/.buildx-cache-new,mode=max --load" - run: make run-e2e-tests-${{ inputs.testsuite_name }} - shell: bash - - - # Temp fix - # https://github.com/docker/build-push-action/issues/252 - # https://github.com/moby/buildkit/issues/1896 - name: Move cache - run: | - rm -rf /tmp/.buildx-cache - mv /tmp/.buildx-cache-new /tmp/.buildx-cache - shell: bash