From f8e8b96de87f3228baabc7fdebf4ab949dfe8f1d Mon Sep 17 00:00:00 2001 From: Jonathan West Date: Thu, 4 Jul 2024 06:54:02 -0400 Subject: [PATCH 1/2] Add CI check to ensure generated artifacts are up to date Signed-off-by: Jonathan West --- .github/workflows/codegen.yaml | 59 ++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 .github/workflows/codegen.yaml diff --git a/.github/workflows/codegen.yaml b/.github/workflows/codegen.yaml new file mode 100644 index 0000000..ae729b3 --- /dev/null +++ b/.github/workflows/codegen.yaml @@ -0,0 +1,59 @@ +name: Generated code +on: + push: + branches: + - 'main' + pull_request: + paths-ignore: + - "docs/**" + branches: + - 'main' + +jobs: + check-go-modules: + name: "Check for go.mod/go.sum synchronicity" + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v4 + - name: Setup Golang + uses: actions/setup-go@v5 + with: + go-version-file: 'go.mod' + - name: Download all Go modules + run: | + go mod download + - name: Check for tidyness of go.mod and go.sum + run: | + go mod tidy + git diff --exit-code -- . + + check-sdk-codegen: + name: "Check for changes from make bundle" + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v4 + - name: Setup Golang + uses: actions/setup-go@v5 + with: + go-version-file: 'go.mod' + - name: Run make bundle + run: | + make bundle + - name: Ensure there is no diff in bundle + # --ignore-matching-lines='.*createdAt:.*' added to ignore bundle differences of timestamp that is generated by upgraded operator-sdk + run: | + git diff --ignore-matching-lines='.*createdAt:.*' --exit-code -- . + - name: Run make generate + run: | + make generate + - name: Ensure there is no diff in generated assets + run: | + git diff --ignore-matching-lines='.*createdAt:.*' --exit-code -- . + - name: Run make manifests + run: | + make manifests + - name: Ensure there is no diff in manifests + run: | + git diff --ignore-matching-lines='.*createdAt:.*' --exit-code -- . From 83c970dcef69818285300079590af5dce2f5340c Mon Sep 17 00:00:00 2001 From: Jonathan West Date: Tue, 31 Dec 2024 11:03:50 -0500 Subject: [PATCH 2/2] Regenerate bundle to include HA fields Signed-off-by: Jonathan West --- bundle/manifests/argoproj.io_rolloutmanagers.yaml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/bundle/manifests/argoproj.io_rolloutmanagers.yaml b/bundle/manifests/argoproj.io_rolloutmanagers.yaml index 3c9a0a6..d684f7a 100644 --- a/bundle/manifests/argoproj.io_rolloutmanagers.yaml +++ b/bundle/manifests/argoproj.io_rolloutmanagers.yaml @@ -228,6 +228,15 @@ spec: items: type: string type: array + ha: + description: HA options for High Availability support for Rollouts. + properties: + enabled: + description: Enabled will toggle HA support globally for RolloutManager. + type: boolean + required: + - enabled + type: object image: description: Image defines Argo Rollouts controller image (optional) type: string