From 7d78c0c8f4857532ddb3fd3e6bae642871d7feca Mon Sep 17 00:00:00 2001 From: Arek Nawo Date: Tue, 12 Sep 2023 22:17:50 +0200 Subject: [PATCH] Update main.yml --- .github/workflows/main.yml | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index a6b26fe6..bf21e264 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,7 +1,7 @@ name: Build & publish on: - release: - types: [published] + push: + branches: ['feature/self-hosting'] env: REGISTRY: ghcr.io @@ -15,13 +15,13 @@ jobs: matrix: include: - dockerfile: ./apps/backend/app/Dockerfile - image: ghcr.io/vrite/app + image: vrite/app - dockerfile: ./apps/backend/api/Dockerfile - image: ghcr.io/vrite/api + image: vrite/api - dockerfile: ./apps/backend/collaboration/Dockerfile - image: ghcr.io/vrite/collaboration + image: vrite/collaboration - dockerfile: ./apps/backend/assets/Dockerfile - image: ghcr.io/vrite/assets + image: vrite/assets permissions: contents: read packages: write @@ -31,20 +31,20 @@ jobs: uses: actions/checkout@v2 - name: Log in to the Container registry - uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9 + uses: docker/login-action@65b78e6e13532edd9afa3aa52ac7964289d1a9c1 with: registry: ${{ env.REGISTRY }} username: ${{ github.actor }} - password: ${{ secrets.GH_PACKAGE_TOKEN }} + password: ${{ secrets.GITHUB_TOKEN }} - name: Extract metadata (tags, labels) for Docker id: meta - uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38 + uses: docker/metadata-action@9ec57ed1fcdbf14dcef7dfbe97b2010124a938b7 with: - images: ${{ matrix.image }} + images: ${{ env.REGISTRY }}/${{ matrix.image }} - name: Build and push Docker image - uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc + uses: docker/build-push-action@f2a1d5e99d037542a71f64918e516c093c6f3fc4 with: context: . file: ${{ matrix.dockerfile }}