From ad3dca3e2705b87a9c9c0b35f67773bcc182ae88 Mon Sep 17 00:00:00 2001 From: Stan Girard Date: Fri, 18 Aug 2023 18:29:02 +0200 Subject: [PATCH] feat(docker): pushing image to github registry --- .github/workflows/aws-preview.yml | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/.github/workflows/aws-preview.yml b/.github/workflows/aws-preview.yml index 9ebaec27bcb6..e9bfd481ce6a 100644 --- a/.github/workflows/aws-preview.yml +++ b/.github/workflows/aws-preview.yml @@ -3,8 +3,8 @@ name: Deploy Backend to Preview ECS on: push: branches: [ "main" ] - paths: - - 'backend/core/**' + # paths: + # - 'backend/core/**' env: AWS_REGION: eu-west-3 @@ -33,6 +33,13 @@ jobs: id: login-ecr uses: aws-actions/amazon-ecr-login@v1 + - name: Login to GitHub Container Registry + uses: docker/login-action@v2 + with: + registry: ghcr.io + username: ${{ github.repository_owner }} + password: ${{ secrets.GITHUB_TOKEN }} + - name: Set up Docker Buildx uses: docker/setup-buildx-action@v2 @@ -51,7 +58,7 @@ jobs: with: context: ./backend/core/ push: true - tags: ${{ env.ECR_REGISTRY }}/${{ env.ECR_REPOSITORY }}:${{ env.IMAGE_TAG }}, ${{ env.ECR_REGISTRY }}/${{ env.ECR_REPOSITORY }}:latest + tags: ${{ env.ECR_REGISTRY }}/${{ env.ECR_REPOSITORY }}:${{ env.IMAGE_TAG }}, ${{ env.ECR_REGISTRY }}/${{ env.ECR_REPOSITORY }}:latest, ghcr.io/quivr/quivr:${{ env.IMAGE_TAG }}, ghcr.io/quivr/quivr:latest cache-from: type=gha cache-to: type=gha,mode=max