From bc67beb84af93fb149871ba17a4f5da7cc19090d Mon Sep 17 00:00:00 2001 From: Jean du Plessis Date: Wed, 30 Oct 2024 14:02:42 +0200 Subject: [PATCH] Remove no longer needed GitHub workflows (#1545) --- .../workflows/publish-service-artifacts.yml | 49 ------ .github/workflows/scan.yml | 52 ------ .github/workflows/updoc.yml | 17 -- .github/workflows/uptest-all.yml | 161 ------------------ 4 files changed, 279 deletions(-) delete mode 100644 .github/workflows/publish-service-artifacts.yml delete mode 100644 .github/workflows/scan.yml delete mode 100644 .github/workflows/updoc.yml delete mode 100644 .github/workflows/uptest-all.yml diff --git a/.github/workflows/publish-service-artifacts.yml b/.github/workflows/publish-service-artifacts.yml deleted file mode 100644 index 44f9cf5330..0000000000 --- a/.github/workflows/publish-service-artifacts.yml +++ /dev/null @@ -1,49 +0,0 @@ -# SPDX-FileCopyrightText: 2024 The Crossplane Authors -# -# SPDX-License-Identifier: CC0-1.0 - -name: Publish Service Artifacts - -on: - workflow_dispatch: - inputs: - subpackages: - description: 'Subpackages to be built individually (e.g. monolith config ec2)' - default: 'monolith' - required: false - size: - description: "Number of smaller provider packages to build and push with each build job" - default: '30' - required: true - concurrency: - description: "Number of parallel package builds within each build job" - default: '1' - required: false - regorg: - description: 'Package registry and organization where the packages will be pushed or (e.g. xpkg.upbound.io/upbound)' - default: 'xpkg.upbound.io/upbound' - required: false - branch_name: - description: "Branch name to use while publishing the packages (e.g. main)" - default: '' - required: false - version: - description: "Version string to use while publishing the packages (e.g. v1.0.0-alpha.1)" - default: '' - required: false - -jobs: - publish-service-artifacts: - uses: upbound/official-providers-ci/.github/workflows/provider-publish-service-artifacts.yml@standard-runners - with: - subpackages: ${{ github.event.inputs.subpackages }} - size: ${{ github.event.inputs.size }} - concurrency: ${{ github.event.inputs.concurrency }} - regorg: ${{ github.event.inputs.regorg }} - branch_name: ${{ github.event.inputs.branch_name }} - version: ${{ github.event.inputs.version }} - go-version: 1.22 - cleanup-disk: true - secrets: - UPBOUND_MARKETPLACE_PUSH_ROBOT_USR: ${{ secrets.UPBOUND_MARKETPLACE_PUSH_ROBOT_USR_RC }} - UPBOUND_MARKETPLACE_PUSH_ROBOT_PSW: ${{ secrets.UPBOUND_MARKETPLACE_PUSH_ROBOT_PSW_RC }} diff --git a/.github/workflows/scan.yml b/.github/workflows/scan.yml deleted file mode 100644 index ab6366bebf..0000000000 --- a/.github/workflows/scan.yml +++ /dev/null @@ -1,52 +0,0 @@ -# SPDX-FileCopyrightText: 2024 The Crossplane Authors -# -# SPDX-License-Identifier: CC0-1.0 - -name: Scan - - -on: - workflow_dispatch: - inputs: - supported_releases_number: - description: 'Number of supported releases' - type: number - default: 1 - schedule: - # run every day at 3:07am UTC - - cron: '7 3 * * *' - -permissions: - security-events: write - -env: - SUPPORTED_RELEASES_NUMBER: '1' - # comma separated list of images, without tag - IMAGES: "xpkg.upbound.io/upbound/provider-family-aws" - -jobs: - setup-vars: - runs-on: ubuntu-24.04 - outputs: - supported_releases_number: ${{ steps.setup.outputs.supported_releases_number }} - images: ${{ steps.setup.outputs.images }} - steps: - - name: Setup outputs - shell: bash - id: setup - run: | - supported_releases_number="${{ fromJSON(inputs.supported_releases_number || env.SUPPORTED_RELEASES_NUMBER) }}" - echo "supported_releases_number=${supported_releases_number}" >> $GITHUB_OUTPUT - - images="${{ env.IMAGES }}" - echo "images=${images}" >> $GITHUB_OUTPUT - - echo "We are going to scan the last ${supported_releases_number} releases for: ${images}" - - scan: - uses: upbound/official-providers-ci/.github/workflows/scan.yml@standard-runners - needs: - - setup-vars - with: - images: ${{ needs.setup-vars.outputs.images }} - supported_releases: ${{ fromJSON(needs.setup-vars.outputs.supported_releases_number) }} diff --git a/.github/workflows/updoc.yml b/.github/workflows/updoc.yml deleted file mode 100644 index cdf2e52a8f..0000000000 --- a/.github/workflows/updoc.yml +++ /dev/null @@ -1,17 +0,0 @@ -# SPDX-FileCopyrightText: 2024 The Crossplane Authors -# -# SPDX-License-Identifier: CC0-1.0 - -name: Updoc - -on: - workflow_dispatch: {} - -jobs: - publish-docs: - uses: upbound/official-providers-ci/.github/workflows/provider-updoc.yml@standard-runners - with: - providers: "config" - go-version: 1.22 - secrets: - UPBOUND_CI_PROD_BUCKET_SA: ${{ secrets.UPBOUND_CI_PROD_BUCKET_SA }} diff --git a/.github/workflows/uptest-all.yml b/.github/workflows/uptest-all.yml deleted file mode 100644 index e8c0a5507b..0000000000 --- a/.github/workflows/uptest-all.yml +++ /dev/null @@ -1,161 +0,0 @@ -# SPDX-FileCopyrightText: 2024 The Crossplane Authors -# -# SPDX-License-Identifier: CC0-1.0 - -name: Uptest All - -on: - workflow_dispatch: {} - -env: - # Common versions - GO_VERSION: '1.22' - DOCKER_BUILDX_VERSION: 'v0.8.2' - -jobs: - detect-api-groups: - runs-on: ubuntu-24.04 - outputs: - api_groups: ${{ steps.api-groups.outputs.list }} - steps: - - name: Checkout - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 - with: - submodules: true - - name: Detect Api Groups - id: api-groups - run: | - export API_GROUPS="" - for i in $(ls -d examples/*/); do API_GROUPS="${API_GROUPS},${i}"; done - - OUTPUT=$(python3 -c "\ - import os, sys; \ - value = os.getenv('API_GROUPS'); \ - list = value.split(','); \ - print(list[1:]); \ - ") - echo "Api Groups: $OUTPUT" - echo "list=${OUTPUT}" >> $GITHUB_OUTPUT - - uptest: - runs-on: ubuntu-24.04 - needs: detect-api-groups - strategy: - fail-fast: false - matrix: - api-groups: ${{ fromJson(needs.detect-api-groups.outputs.api_groups) }} - exclude: - - api-groups: examples/providerconfig/ - steps: - - name: Setup QEMU - uses: docker/setup-qemu-action@49b3bc8e6bdd4a60e6116a5414239cba5943d3cf # v3 - with: - platforms: all - - - name: Setup Docker Buildx - uses: docker/setup-buildx-action@c47758b77c9736f4b2ef4073d4d51994fabfe349 # v3 - with: - version: ${{ env.DOCKER_BUILDX_VERSION }} - install: true - - - name: Checkout - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 - with: - submodules: true - - - name: Fetch History - run: git fetch --prune --unshallow - - - name: Setup Go - uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5 - with: - go-version: ${{ env.GO_VERSION }} - - - name: Find the Go Build Cache - id: go - run: echo "cache=$(go env GOCACHE)" >> $GITHUB_OUTPUT - - - name: Cache the Go Build Cache - uses: actions/cache@6849a6489940f00c2f30c0fb92c6274307ccb58a # v4 - with: - path: ${{ steps.go.outputs.cache }} - key: ${{ runner.os }}-build-uptest-${{ hashFiles('**/go.sum') }} - restore-keys: ${{ runner.os }}-build-uptest- - - - name: Cache Go Dependencies - uses: actions/cache@6849a6489940f00c2f30c0fb92c6274307ccb58a # v4 - with: - path: .work/pkg - key: ${{ runner.os }}-pkg-${{ hashFiles('**/go.sum') }} - restore-keys: ${{ runner.os }}-pkg- - - - name: Vendor Dependencies - run: make vendor vendor.check - - - name: Build Artifacts - run: make -j2 build.all - env: - # We're using docker buildx, which doesn't actually load the images it - # builds by default. Specifying --load does so. - BUILD_ARGS: "--load" - - - name: Prepare The Example List - id: prepare-example-list - run: | - cd .. - EXAMPLE_LIST="" - EXAMPLE_LIST="${EXAMPLE_LIST},$(find ${{ matrix.api-groups }} -name '*.yaml' | tr '\n' ',')" - echo "example-list=${EXAMPLE_LIST:1}" >> $GITHUB_OUTPUT - echo "Examples: ${EXAMPLE_LIST:1}" - - - name: Run Uptest - id: run-uptest - env: - UPTEST_AWS_CREDS: ${{ secrets.UPTEST_AWS_CREDS }} - EXAMPLE_LIST: ${{ needs.get-example-list.outputs.example_list }} - UPTEST_EXAMPLE_VALUE_REPLACEMENTS: ${{ secrets.UPTEST_EXAMPLE_VALUE_REPLACEMENTS }} - DUMP_DIRECTORY: "./_output/cluster-dump" - run: make uptest - - - name: Collect Cluster Dump - if: always() - run: | - export DUMP_DIRECTORY=./_output/cluster-dump - make cluster_dump - - - name: Upload Cluster Dump - if: always() - uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4 - with: - name: cluster-dump-aws - path: ./_output/cluster-dump - - - name: Cleanup - if: always() - run: | - kubectl delete managed --all - - report: - runs-on: ubuntu-24.04 - needs: uptest - if: always() - env: - GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} - steps: - - name: Checkout - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 - with: - submodules: true - - name: Manual Intervention Report - run: | - echo "Total Resources for AWS: $(cat examples/*/* | grep -o "kind: " | wc -l)" - echo "Number of Skipped Resources: $(grep -r -o "upjet.upbound.io/manual-intervention" examples/* | wc -l)" - echo "Skipped Manifests (Manual Intervention): $(grep -r -o "upjet.upbound.io/manual-intervention" examples/*)" - - name: Coverage Report - run: | - OUTPUT=$(gh api -H "Accept: application/vnd.github+json" /repos/${{ github.repository }}/actions/runs/${{ github.run_id }}/jobs | jq '.jobs | .[] | select(.name!="detect-api-groups" and .name!="report") | .name + " -> " + .conclusion') - FAILURE=$(echo ${OUTPUT} | grep -o 'failure' | wc -l) - SUCCESS=$(echo ${OUTPUT} | grep -o 'success' | wc -l) - echo "Success: ${SUCCESS}" - echo "Failure: ${FAILURE}" - echo "${OUTPUT}"