diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 4f469cde..dfc7097a 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -63,6 +63,45 @@ jobs: export CI_COMMIT_REF_SLUG=${{ steps.slug.outputs.branch-name-slug }} make push_gcp_controller + publish: + name: Publish Image on Docker Hub + runs-on: ubuntu-latest + if: ${{ inputs.env == 'production' }} + container: ghcr.io/uffizzicloud/controller_toolbox:v2 + steps: + - name: Checkout + uses: actions/checkout@v2 + - uses: gacts/github-slug@v1 + id: slug + - id: 'ci_registry_auth' + name: 'Authenticate to Google Cloud' + uses: 'google-github-actions/auth@v0' + with: + token_format: 'access_token' + workload_identity_provider: ${{ secrets.CI_IDENTITY_PROVIDER_LOCATION }} + service_account: ${{ secrets.CI_SERVICE_ACCOUNT_NAME }} + - name: Login to GCR + uses: docker/login-action@v2 + with: + registry: gcr.io + username: oauth2accesstoken + password: ${{ steps.ci_registry_auth.outputs.access_token }} + - name: Pull and tag CI image + run: make pull_ci_image + - name: Login to DockerHub + uses: docker/login-action@v2 + with: + username: ${{ secrets.DOCKERHUB_USERNAME }} + password: ${{ secrets.DOCKERHUB_PASSWORD }} + - name: Publish Controller Image + run: make publish_image + - name: Update Docker Hub Description + uses: peter-evans/dockerhub-description@v3 + with: + username: ${{ secrets.DOCKERHUB_USERNAME }} + password: ${{ secrets.DOCKERHUB_PASSWORD }} + repository: uffizzi/controller + update-gke-controller: runs-on: ubuntu-latest needs: diff --git a/.github/workflows/helm-release.yml b/.github/workflows/helm-release.yml index de7e7921..d977e355 100644 --- a/.github/workflows/helm-release.yml +++ b/.github/workflows/helm-release.yml @@ -20,6 +20,6 @@ jobs: git config user.email "$GITHUB_ACTOR@users.noreply.github.com" - name: Run chart-releaser - uses: helm/chart-releaser-action@v1.3.0 + uses: helm/chart-releaser-action@v1.5.0 env: CR_TOKEN: "${{ secrets.GITHUB_TOKEN }}" diff --git a/Makefile b/Makefile index c50bd595..2b7d759e 100644 --- a/Makefile +++ b/Makefile @@ -88,6 +88,12 @@ tag_image: docker tag ${CONTROLLER_IMAGE}:${SHORT_VERSION} ${GCP_CONTROLLER_IMAGE}:${CI_COMMIT_REF_SLUG} || true docker tag ${CONTROLLER_IMAGE}:${SHORT_VERSION} ${GCP_CONTROLLER_IMAGE}:latest +publish_image: + docker tag ${CONTROLLER_IMAGE}:${SHORT_VERSION} uffizzi/controller:latest + docker tag ${CONTROLLER_IMAGE}:${SHORT_VERSION} uffizzi/controller:${SHORT_VERSION} + docker push uffizzi/controller:latest + docker push uffizzi/controller:${SHORT_VERSION} + push_gcp_controller: docker push ${GCP_CONTROLLER_IMAGE}:${VERSION} docker push ${GCP_CONTROLLER_IMAGE}:${SHORT_VERSION} diff --git a/charts/uffizzi-controller/Chart.yaml b/charts/uffizzi-controller/Chart.yaml index ce946721..9e00f7fb 100644 --- a/charts/uffizzi-controller/Chart.yaml +++ b/charts/uffizzi-controller/Chart.yaml @@ -1,6 +1,6 @@ apiVersion: v2 name: uffizzi-controller -version: 1.0.1 +version: 1.0.2 kubeVersion: ">= 1.21.6-0" # https://issuetracker.google.com/issues/77503699 description: "A smart proxy service that handles requests from Uffizzi App to the Kubernetes API - 1 of 3 services (controller, uffizzi_app, uffizzi_cli) that comprise the uffizzi full-stack previews engine which automates trigger-based on-demand preview environments" type: application @@ -18,17 +18,16 @@ keywords: home: https://uffizzi.com/ sources: - https://github.com/UffizziCloud/uffizzi_controller - - https://gitlab.com/dualbootpartners/idyl/uffizzi_controller dependencies: - name: ingress-nginx - version: "~4.0.18" + version: "~4.0.19" repository: https://kubernetes.github.io/ingress-nginx # condition: # tags: # import-values: # alias: - name: cert-manager - version: "~1.7.2" + version: "~1.7.3" repository: https://charts.jetstack.io # condition: # tags: