From 4890a9749ca2f82fae114f5540ce7afb721a418c Mon Sep 17 00:00:00 2001 From: Yuki Takei Date: Thu, 28 Mar 2024 09:18:41 +0000 Subject: [PATCH] omit configurations --- .github/workflows/release-rc.yml | 23 --------------- .github/workflows/release-slackbot-proxy.yml | 9 +----- .github/workflows/release.yml | 29 ++----------------- .../workflows/reusable-app-build-image.yml | 1 - apps/app/docker/codebuild/buildspec.yml | 7 +---- 5 files changed, 4 insertions(+), 65 deletions(-) diff --git a/.github/workflows/release-rc.yml b/.github/workflows/release-rc.yml index c604c2fd41c..4e05a883d1e 100644 --- a/.github/workflows/release-rc.yml +++ b/.github/workflows/release-rc.yml @@ -18,7 +18,6 @@ jobs: outputs: TAGS: ${{ steps.meta.outputs.tags }} - TAGS_GHCR: ${{ steps.meta-ghcr.outputs.tags }} steps: - uses: actions/checkout@v3 @@ -37,16 +36,6 @@ jobs: type=raw,value=${{ steps.package-json.outputs.packageVersion }} type=raw,value=${{ steps.package-json.outputs.packageVersion }}.{{sha}} - - name: Docker meta for ghcr.io - uses: docker/metadata-action@v4 - id: meta-ghcr - with: - images: ghcr.io/weseek/growi - sep-tags: ',' - tags: | - type=raw,value=${{ steps.package-json.outputs.packageVersion }} - type=raw,value=${{ steps.package-json.outputs.packageVersion }}.{{sha}} - build-image-rc: uses: weseek/growi/.github/workflows/reusable-app-build-image.yml@master @@ -69,15 +58,3 @@ jobs: secrets: DOCKER_REGISTRY_PASSWORD: ${{ secrets.DOCKER_REGISTRY_PASSWORD }} - publish-image-rc-ghcr: - needs: [determine-tags, build-image-rc] - - uses: weseek/growi/.github/workflows/reusable-app-create-manifests.yml@master - with: - tags: ${{ needs.determine-tags.outputs.TAGS_GHCR }} - registry: ghcr.io - image-name: weseek/growi - tag-temporary: latest-rc - secrets: - DOCKER_REGISTRY_PASSWORD: ${{ secrets.DOCKER_REGISTRY_ON_GITHUB_PASSWORD }} - diff --git a/.github/workflows/release-slackbot-proxy.yml b/.github/workflows/release-slackbot-proxy.yml index c53bf78cb4c..f214a5c926e 100644 --- a/.github/workflows/release-slackbot-proxy.yml +++ b/.github/workflows/release-slackbot-proxy.yml @@ -26,7 +26,7 @@ jobs: id: meta uses: docker/metadata-action@v4 with: - images: weseek/growi-slackbot-proxy,ghcr.io/weseek/growi-slackbot-proxy,asia.gcr.io/${{ secrets.GCP_PRJ_ID_SLACKBOT_PROXY }}/growi-slackbot-proxy + images: weseek/growi-slackbot-proxy,asia.gcr.io/${{ secrets.GCP_PRJ_ID_SLACKBOT_PROXY }}/growi-slackbot-proxy tags: | type=raw,value=latest type=raw,value=${{ steps.package-json.outputs.packageVersion }} @@ -35,13 +35,6 @@ jobs: run: | echo ${{ secrets. DOCKER_REGISTRY_PASSWORD }} | docker login --username wsmoogle --password-stdin - - name: Login to GitHub Container Registry - uses: docker/login-action@v2 - with: - registry: ghcr.io - username: wsmoogle - password: ${{ secrets.DOCKER_REGISTRY_ON_GITHUB_PASSWORD }} - - name: Authenticate to Google Cloud for GROWI.cloud uses: google-github-actions/auth@v1 with: diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index aea81e5606e..ad3d84aadd1 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -82,7 +82,6 @@ jobs: outputs: TAGS: ${{ steps.meta.outputs.tags }} - TAGS_GHCR: ${{ steps.meta-ghcr.outputs.tags }} steps: - uses: actions/checkout@v3 @@ -103,18 +102,6 @@ jobs: type=semver,value=${{ needs.create-github-release.outputs.RELEASED_VERSION }},pattern={{major}}.{{minor}} type=semver,value=${{ needs.create-github-release.outputs.RELEASED_VERSION }},pattern={{major}}.{{minor}}.{{patch}} - - name: Docker meta for ghcr.io - uses: docker/metadata-action@v4 - id: meta-ghcr - with: - images: ghcr.io/weseek/growi - sep-tags: ',' - tags: | - type=raw,value=latest - type=semver,value=${{ needs.create-github-release.outputs.RELEASED_VERSION }},pattern={{major}} - type=semver,value=${{ needs.create-github-release.outputs.RELEASED_VERSION }},pattern={{major}}.{{minor}} - type=semver,value=${{ needs.create-github-release.outputs.RELEASED_VERSION }},pattern={{major}}.{{minor}}.{{patch}} - build-image: needs: create-github-release @@ -140,21 +127,9 @@ jobs: secrets: DOCKER_REGISTRY_PASSWORD: ${{ secrets.DOCKER_REGISTRY_PASSWORD }} - publish-image-ghcr: - needs: [determine-tags, build-image] - - uses: weseek/growi/.github/workflows/reusable-app-create-manifests.yml@master - with: - tags: ${{ needs.determine-tags.outputs.TAGS_GHCR }} - registry: ghcr.io - image-name: weseek/growi - tag-temporary: latest - secrets: - DOCKER_REGISTRY_PASSWORD: ${{ secrets.DOCKER_REGISTRY_ON_GITHUB_PASSWORD }} - post-publish: - needs: [create-github-release, publish-image, publish-image-ghcr] + needs: [create-github-release, publish-image] runs-on: ubuntu-latest steps: @@ -179,7 +154,7 @@ jobs: create-pr-for-next-rc: - needs: [create-github-release, publish-image, publish-image-ghcr] + needs: [create-github-release, publish-image] runs-on: ubuntu-latest steps: diff --git a/.github/workflows/reusable-app-build-image.yml b/.github/workflows/reusable-app-build-image.yml index 4b90f613425..9aa0e091faf 100644 --- a/.github/workflows/reusable-app-build-image.yml +++ b/.github/workflows/reusable-app-build-image.yml @@ -52,5 +52,4 @@ jobs: CODEBUILD__environmentTypeOverride: ${{ (matrix.platform == 'amd64' && 'LINUX_CONTAINER') || 'ARM_CONTAINER' }} CODEBUILD__environmentVariablesOverride: '[ { "name": "IMAGE_TAG", "type": "PLAINTEXT", "value": "docker.io/${{ inputs.image-name }}:${{ inputs.tag-temporary }}-${{ matrix.platform }}" }, - { "name": "IMAGE_TAG_GHCR", "type": "PLAINTEXT", "value": "ghcr.io/${{ inputs.image-name }}:${{ inputs.tag-temporary }}-${{ matrix.platform }}" } ]' diff --git a/apps/app/docker/codebuild/buildspec.yml b/apps/app/docker/codebuild/buildspec.yml index e281761d51e..1cbc6fd5c19 100644 --- a/apps/app/docker/codebuild/buildspec.yml +++ b/apps/app/docker/codebuild/buildspec.yml @@ -4,10 +4,8 @@ env: variables: DOCKER_BUILDKIT: 1 IMAGE_TAG: '' - IMAGE_TAG_GHCR: '' secrets-manager: DOCKER_REGISTRY_PASSWORD: growi/official-image-builder:DOCKER_REGISTRY_PASSWORD - DOCKER_REGISTRY_ON_GITHUB_PAT: growi/official-image-builder:DOCKER_REGISTRY_ON_GITHUB_PAT phases: pre_build: @@ -19,17 +17,14 @@ phases: - git-lfs pull # login to docker.io - echo ${DOCKER_REGISTRY_PASSWORD} | docker login --username wsmoogle --password-stdin - # login to ghcr.io - - echo ${DOCKER_REGISTRY_ON_GITHUB_PAT} | docker login ghcr.io --username wsmoogle --password-stdin build: commands: - docker build -t ${IMAGE_TAG} -f ./apps/app/docker/Dockerfile . - - docker tag ${IMAGE_TAG} ${IMAGE_TAG_GHCR} + - docker tag ${IMAGE_TAG} post_build: commands: - docker push $IMAGE_TAG - - docker push $IMAGE_TAG_GHCR cache: paths: