Skip to content

Commit 7800fbc

Browse files
committed
Trigger gcp-deploy
1 parent 76bc589 commit 7800fbc

2 files changed

Lines changed: 11 additions & 5 deletions

File tree

.github/workflows/ci-docker.yml

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -75,29 +75,35 @@ jobs:
7575
deploy-gcp:
7676
needs: docker-image
7777
runs-on: ubuntu-latest
78+
permissions:
79+
contents: read
80+
packages: read
7881

7982
steps:
8083
- name: Checkout repository
8184
uses: actions/checkout@v4
8285

86+
- name: Authenticate to Google Cloud
87+
uses: google-github-actions/auth@v2
88+
with:
89+
credentials_json: ${{ secrets.GCP_SERVICE_ACCOUNT_KEY }}
90+
8391
- name: Set up gcloud
8492
uses: google-github-actions/setup-gcloud@v2
8593
with:
86-
service_account_key: ${{ secrets.GCP_SERVICE_ACCOUNT_KEY }}
8794
project_id: ${{ secrets.GCP_PROJECT_ID }}
88-
export_default_credentials: true
8995

9096
- name: Configure Docker for Artifact Registry
9197
run: |
92-
gcloud auth configure-docker us-east1-docker.pkg.dev
98+
gcloud auth configure-docker us-east1-docker.pkg.dev --quiet
9399
94100
- name: Pull image from GHCR
95101
run: |
96102
IMAGE_ID=ghcr.io/${{ github.repository_owner }}/mcp-backend
97103
VERSION=${{ github.sha }}
98104
echo "IMAGE_ID=$IMAGE_ID" >> $GITHUB_ENV
99105
echo "VERSION=$VERSION" >> $GITHUB_ENV
100-
echo "$GITHUB_TOKEN" | docker login ghcr.io -u "$GITHUB_ACTOR" --password-stdin
106+
echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u "$GITHUB_ACTOR" --password-stdin
101107
docker pull $IMAGE_ID:$VERSION
102108
103109
- name: Tag and push image to Artifact Registry

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ ALTER TABLE public.deployment_logs
195195
└──────────────────────────┘
196196
197197
Adding this line to test the workflows
198-
Another test
198+
Another test2
199199
200200
Test
201201
```

0 commit comments

Comments
 (0)