File tree Expand file tree Collapse file tree 1 file changed +47
-0
lines changed Expand file tree Collapse file tree 1 file changed +47
-0
lines changed Original file line number Diff line number Diff line change
1
+
2
+ name : ' Deploy to Cloud Run'
3
+
4
+ on :
5
+ workflow_run :
6
+ workflows : [dbc]
7
+ types :
8
+ - completed
9
+
10
+ env :
11
+ PROJECT_ID : ' ${{ secrets.GOOGLE_CLOUD_PROJECT_ID }}' # TODO: update to your Google Cloud project ID
12
+ REGION : ' us-central1' # TODO: update to your region
13
+ SERVICE : ' todo-demo-app' # TODO: update to your service name
14
+
15
+ jobs :
16
+ deploy :
17
+ runs-on : ' ubuntu-latest'
18
+
19
+ permissions :
20
+ contents : ' read'
21
+ id-token : ' write'
22
+
23
+ steps :
24
+ - name : ' Checkout'
25
+ uses : ' actions/checkout@v4' # actions/checkout@v4
26
+
27
+ - id : ' auth'
28
+ name : ' Authenticate to Google Cloud'
29
+ uses : ' google-github-actions/auth@v2' # google-github-actions/auth@v2
30
+ with :
31
+ credentials_json : ' ${{ secrets.GOOGLE_CREDENTIALS }}'
32
+
33
+ - name : ' Deploy to Cloud Run'
34
+
35
+ uses : ' google-github-actions/deploy-cloudrun@v2'
36
+ with :
37
+ service : ' ${{ env.SERVICE }}'
38
+ region : ' ${{ env.REGION }}'
39
+ # NOTE: If using a pre-built image, update the image name below:
40
+
41
+ image : ' docker.io/olegselajev241/todo-demo-application:latest'
42
+
43
+ # If required, use the Cloud Run URL output in later steps
44
+ - name : ' Show output'
45
+ run : |2-
46
+
47
+ echo ${{ steps.deploy.outputs.url }}
You can’t perform that action at this time.
0 commit comments