From 463a1a908a56634f9545fc62083a2f87a86f96c4 Mon Sep 17 00:00:00 2001 From: "Artem Sh." Date: Thu, 18 Jul 2024 09:59:55 +0200 Subject: [PATCH] Change CI related files (#8) --- .github/workflows/automerge.yaml | 42 ++++++++++++++++++++++++++++++++ .github/workflows/ci.yml | 11 +++++++++ Makefile | 8 +++--- README.md | 4 +-- package/crossplane.yaml | 15 ++++++++++++ 5 files changed, 74 insertions(+), 6 deletions(-) create mode 100644 .github/workflows/automerge.yaml diff --git a/.github/workflows/automerge.yaml b/.github/workflows/automerge.yaml new file mode 100644 index 0000000..3146e77 --- /dev/null +++ b/.github/workflows/automerge.yaml @@ -0,0 +1,42 @@ +name: automerge + +on: + pull_request: + types: + - labeled + - unlabeled + - synchronize + - opened + - edited + - ready_for_review + - reopened + - unlocked + pull_request_review: + types: + - submitted + check_suite: + types: + - completed + status: {} + +jobs: + automerge: + runs-on: ubuntu-latest + if: > + contains(github.event.pull_request.labels.*.name, 'gate') + environment: github + steps: + - name: Create GitHub App Token + id: app-token + uses: actions/create-github-app-token@v1 + with: + app-id: ${{ secrets.APP_ID }} + private-key: ${{ secrets.APP_KEY }} + + - id: automerge + name: automerge + uses: pascalgn/automerge-action@v0.16.3 + env: + GITHUB_TOKEN: ${{ steps.app-token.outputs.token }} + MERGE_LABELS: "gate" + MERGE_METHOD: "squash" diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 244d3f1..0473136 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -319,3 +319,14 @@ jobs: - name: Publish Artifacts run: make publish BRANCH_NAME=${GITHUB_REF##*/} + + eco_check: + name: eco/check + if: always() + needs: [detect-noop, report-breaking-changes, lint, check-diff, unit-tests, local-deploy, publish-artifacts] + runs-on: ubuntu-latest + steps: + - name: Decide whether the needed jobs succeeded or failed + uses: re-actors/alls-green@05ac9388f0aebcb5727afa17fcccfecd6f8ec5fe # v1.2.2 + with: + jobs: ${{ toJSON(needs) }} diff --git a/Makefile b/Makefile index 66b69b3..8f40efc 100644 --- a/Makefile +++ b/Makefile @@ -56,7 +56,7 @@ GO_SUBDIRS += cmd internal apis # Setup Kubernetes tools KIND_VERSION = v0.15.0 -UP_VERSION = v0.18.0 +UP_VERSION = v0.28.0 UP_CHANNEL = stable UPTEST_VERSION = v0.5.0 -include build/makelib/k8s_tools.mk @@ -64,17 +64,17 @@ UPTEST_VERSION = v0.5.0 # ==================================================================================== # Setup Images -REGISTRY_ORGS ?= xpkg.upbound.io/upbound +REGISTRY_ORGS ?= xpkg.upbound.io/opentelekomcloud IMAGES = $(PROJECT_NAME) -include build/makelib/imagelight.mk # ==================================================================================== # Setup XPKG -XPKG_REG_ORGS ?= xpkg.upbound.io/upbound +XPKG_REG_ORGS ?= xpkg.upbound.io/opentelekomcloud # NOTE(hasheddan): skip promoting on xpkg.upbound.io as channel tags are # inferred. -XPKG_REG_ORGS_NO_PROMOTE ?= xpkg.upbound.io/upbound +XPKG_REG_ORGS_NO_PROMOTE ?= xpkg.upbound.io/opentelekomcloud XPKGS = $(PROJECT_NAME) -include build/makelib/xpkg.mk diff --git a/README.md b/README.md index 0f3c5f7..4ae7716 100644 --- a/README.md +++ b/README.md @@ -21,13 +21,13 @@ kind: Provider metadata: name: provider-opentelekomcloud spec: - package: opentelekomcloud/provider-opentelekomcloud:v0.1.0 + package: xpkg.upbound.io/opentelekomcloud/provider-opentelekomcloud:v0.1.0 EOF ``` Notice that in this example Provider resource is referencing ControllerConfig with debug enabled. -You can see the API reference [here](https://doc.crds.dev/github.com/opentelekomcloud/provider-opentelekomcloud). +You can see the API reference [here](https://marketplace.upbound.io/providers/opentelekomcloud/provider-opentelekomcloud/latest). ## Developing diff --git a/package/crossplane.yaml b/package/crossplane.yaml index e020f25..c0aeb06 100644 --- a/package/crossplane.yaml +++ b/package/crossplane.yaml @@ -2,3 +2,18 @@ apiVersion: meta.pkg.crossplane.io/v1 kind: Provider metadata: name: provider-opentelekomcloud + annotations: + meta.crossplane.io/maintainer: OTC Ecosystem Squad + meta.crossplane.io/source: github.com/opentelekomcloud/provider-opentelekomcloud + meta.crossplane.io/license: Apache-2.0 + meta.crossplane.io/description: | + The OpenTelekomCloud Crossplane provider adds support for + managing OTC resources in Kubernetes. + + meta.crossplane.io/readme: | + `provider-opentelekomcloud` is the Crossplane infrastructure provider for [OpenTelekomCloud (OTC)](https://www.open-telekom-cloud.com/). + + ## Report a Bug + + If you encounter any bugs, have suggestions for improvements, or want to request new features, please + open an [issue](https://github.com/opentelekomcloud/provider-opentelekomcloud/issues).