diff --git a/.github/workflows/build-push-images.yaml b/.github/workflows/build-push-images.yaml index 148e0757..86c2fe53 100644 --- a/.github/workflows/build-push-images.yaml +++ b/.github/workflows/build-push-images.yaml @@ -3,10 +3,9 @@ name: Build and Push images on: push: branches: - - 'release/v[0-9].[0-9]' + - main tags: - v* - workflow_dispatch: jobs: @@ -56,26 +55,24 @@ jobs: uses: docker/metadata-action@v4 with: images: | - percona/everest-operator,enable=${{ github.ref_type == 'tag' && !contains(github.ref_name, 'dev') }} + percona/everest-operator,enable=${{ github.ref_type == 'tag' && !contains(github.ref_name, 'rc') }} perconalab/everest-operator tags: | type=match,pattern=v(.*),group=1 - type=match,pattern=v(\d.\d),group=1,enable=${{ !contains(github.ref_name, 'dev') }} - type=raw,value=latest,enable=${{ !contains(github.ref_name, 'dev') }} - type=sha + type=match,pattern=v(\d.\d),group=1,enable=${{ !contains(github.ref_name, 'main') }} + type=raw,value=latest,enable=${{ !contains(github.ref_name, 'rc') }} - name: Docker bundle meta id: bundle_meta uses: docker/metadata-action@v4 with: images: | - percona/everest-operator-bundle,enable=${{ github.ref_type == 'tag' && !contains(github.ref_name, 'dev') }} + percona/everest-operator-bundle,enable=${{ github.ref_type == 'tag' && !contains(github.ref_name, 'rc') }} perconalab/everest-operator-bundle tags: | type=match,pattern=v(.*),group=1 - type=match,pattern=v(\d.\d),group=1,enable=${{ !contains(github.ref_name, 'dev') }} - type=raw,value=latest,enable=${{ !contains(github.ref_name, 'dev') }} - type=sha + type=match,pattern=v(\d.\d),group=1,enable=${{ !contains(github.ref_name, 'main') }} + type=raw,value=latest,enable=${{ !contains(github.ref_name, 'rc') }} - name: Login to GitHub Container Registry uses: docker/login-action@v2 diff --git a/.github/workflows/checks.yml b/.github/workflows/checks.yml index b2009d71..fca26cc2 100644 --- a/.github/workflows/checks.yml +++ b/.github/workflows/checks.yml @@ -55,6 +55,19 @@ jobs: # use GITHUB_TOKEN because only it has access to GitHub Checks API bin/golangci-lint run --out-format=line-number | env REVIEWDOG_GITHUB_API_TOKEN=${{ secrets.GITHUB_TOKEN }} bin/reviewdog -f=golangci-lint -reporter=github-pr-review -filter-mode=nofilter -fail-on-error=true + - name: Check default main state - dev version + run: | + if ! grep -q "VERSION ?= 0.0.0" Makefile; then + echo "default VERSION in Makefile should be 0.0.0" + exit 1 + fi + + - name: Check default main state - generated files + run: | + make release + echo "Checking there is no source code changes except of the file with the generated date after a release attempt" + git diff --exit-code $(git ls-files | grep -v "bundle/manifests/everest-operator.clusterserviceversion.yaml") + - name: Run debug commands on failure if: ${{ failure() }} run: | diff --git a/Makefile b/Makefile index 23e0f5e2..00a34adc 100644 --- a/Makefile +++ b/Makefile @@ -3,7 +3,7 @@ # To re-generate a bundle for another specific version without changing the standard setup, you can: # - use the VERSION as arg of the bundle target (e.g make bundle VERSION=0.0.2) # - use environment variables to overwrite this value (e.g export VERSION=0.0.2) -VERSION ?= 0.6.0-dev2 +VERSION ?= 0.0.0 # CHANNELS define the bundle channels used in the bundle. # Add a new line here if you would like to change its default config. (E.g CHANNELS = "candidate,fast,stable") diff --git a/bundle/manifests/everest-operator.clusterserviceversion.yaml b/bundle/manifests/everest-operator.clusterserviceversion.yaml index 487dd2c0..ca910b94 100644 --- a/bundle/manifests/everest-operator.clusterserviceversion.yaml +++ b/bundle/manifests/everest-operator.clusterserviceversion.yaml @@ -103,10 +103,10 @@ metadata: } ] capabilities: Basic Install - createdAt: "2023-12-21T09:54:14Z" + createdAt: "2023-12-27T09:53:47Z" operators.operatorframework.io/builder: operator-sdk-v1.32.0 operators.operatorframework.io/project_layout: go.kubebuilder.io/v3 - name: everest-operator.v0.6.0-dev2 + name: everest-operator.v0.0.0 namespace: placeholder spec: apiservicedefinitions: {} @@ -551,7 +551,7 @@ spec: valueFrom: fieldRef: fieldPath: metadata.namespace - image: docker.io/perconalab/everest-operator:0.6.0-dev2 + image: docker.io/perconalab/everest-operator:0.0.0 livenessProbe: httpGet: path: /healthz @@ -645,4 +645,4 @@ spec: provider: name: Percona url: https://percona.com - version: 0.6.0-dev2 + version: 0.0.0 diff --git a/config/manager/kustomization.yaml b/config/manager/kustomization.yaml index 8a7b9ae2..bbbdb040 100644 --- a/config/manager/kustomization.yaml +++ b/config/manager/kustomization.yaml @@ -5,4 +5,4 @@ kind: Kustomization images: - name: controller newName: docker.io/perconalab/everest-operator - newTag: 0.6.0-dev2 + newTag: 0.0.0 diff --git a/deploy/bundle.yaml b/deploy/bundle.yaml index 1825f0ba..49ea973e 100644 --- a/deploy/bundle.yaml +++ b/deploy/bundle.yaml @@ -1448,7 +1448,7 @@ spec: valueFrom: fieldRef: fieldPath: metadata.namespace - image: docker.io/perconalab/everest-operator:0.6.0-dev2 + image: docker.io/perconalab/everest-operator:0.0.0 livenessProbe: httpGet: path: /healthz