forked from prefeitura-rio/emd-desafio-devops
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
214a50d
commit dc896ca
Showing
1 changed file
with
6 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,7 +6,7 @@ on: | |
- main | ||
|
||
env: | ||
PROJECT_ID: test13-01 # TODO: update Google Cloud project id | ||
PROJECT_ID: ${{ secrets.GCP_PROJECT_ID }} # TODO: update Google Cloud project id | ||
SERVICE: emd-desafio-devops-caio # TODO: update Cloud Run service name | ||
REGION: us-central1-c # TODO: update Cloud Run service region | ||
|
||
|
@@ -22,19 +22,12 @@ jobs: | |
- name: Checkout | ||
uses: actions/checkout@v2 | ||
|
||
- name: Google Auth | ||
id: auth | ||
uses: "google-github-actions/auth@v0" | ||
- name: Setup Google Cloud CLI | ||
uses: google-github-actions/[email protected] | ||
with: | ||
workload_identity_provider: "${{ secrets.WIF_PROVIDER }}" # e.g. - projects/123456789/locations/global/workloadIdentityPools/my-pool/providers/my-provider | ||
service_account: "${{ secrets.WIF_SERVICE_ACCOUNT }}" # e.g. - [email protected] | ||
|
||
# NOTE: Alternative option - authentication via credentials json | ||
# - name: Google Auth | ||
# id: auth | ||
# uses: 'google-github-actions/auth@v0' | ||
# with: | ||
# credentials_json: '${{ secrets.GCP_CREDENTIALS }}' | ||
service_account_key: ${{ secrets.GCP_SA_KEY }} | ||
project_id: ${{ secrets.GCP_PROJECT_ID }} | ||
export_default_credentials: true | ||
|
||
- name: Deploy to Cloud Run | ||
id: deploy | ||
|