generated from ONSdigital/ons-python-template
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcloudbuild-dev.yaml
33 lines (30 loc) · 1.02 KB
/
cloudbuild-dev.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
steps:
# Build the container image
- name: "gcr.io/cloud-builders/docker"
args: ["build", "-f", "Dockerfile", "-t", "europe-west2-docker.pkg.dev/${PROJECT_ID}/docker-images/cir-converter-service:$SHORT_SHA", "."]
# Push the container image to Google Artifact Registry
- name: "gcr.io/cloud-builders/docker"
args: ["push", "europe-west2-docker.pkg.dev/${PROJECT_ID}/docker-images/cir-converter-service:$SHORT_SHA"]
# Deploy the container to Google Cloud Run
- name: "gcr.io/google.com/cloudsdktool/cloud-sdk"
id: "Run container"
entrypoint: gcloud
args:
[
"run",
"deploy",
"cir-converter-service",
"--image",
"europe-west2-docker.pkg.dev/${PROJECT_ID}/docker-images/cir-converter-service:$SHORT_SHA",
"--port",
"5010",
"--region",
"europe-west2",
"--platform",
"managed",
"--allow-unauthenticated",
"--ingress",
"internal-and-cloud-load-balancing",
]
options:
logging: CLOUD_LOGGING_ONLY