forked from GoogleCloudPlatform/bank-of-anthos
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathcloudbuild-mvnw.yaml
40 lines (40 loc) · 1.35 KB
/
cloudbuild-mvnw.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
34
35
36
37
38
39
40
steps:
- name: gcr.io/cloud-builders/gsutil
args: ['cp', $_CACHE_URI, '/workspace/cache']
- name: gcr.io/k8s-skaffold/skaffold:v1.37.2-lts
args:
- "/workspace/mvnw"
- "jib:_skaffold-fail-if-jib-out-of-date"
- "-Djib.requiredVersion=1.4.0"
- "--projects"
- "src/ledger/balancereader"
- "--also-make"
- "jib:_skaffold-files-v2"
- "--batch-mode"
env:
- "MAVEN_USER_HOME=/workspace/.m2"
- name: gcr.io/k8s-skaffold/skaffold:v1.37.2-lts
args:
- "skaffold"
- "build"
- "--file-output=/workspace/artifacts.json"
- "--default-repo=$_CONTAINER_REGISTRY"
- "--cache-file=/workspace/$_CACHE" # set _CACHE to anything other than "cache" e.g. "no-cache" to reset skaffold cache
- "--filename=src/$_TEAM/skaffold.yaml"
env:
- "MAVEN_USER_HOME=/workspace/.m2"
- name: gcr.io/cloud-builders/gsutil
args: ['cp', '/workspace/$_CACHE', $_CACHE_URI]
- name: gcr.io/cloud-builders/gcloud
args:
- "deploy"
- "releases"
- "create"
- "$_TEAM-$SHORT_SHA"
- "--delivery-pipeline=$_TEAM"
- "--build-artifacts=/workspace/artifacts.json"
- "--skaffold-file=src/$_TEAM/skaffold.yaml"
- "--region=europe-west1"
- "--gcs-source-staging-dir=$_SOURCE_STAGING_BUCKET/$SHORT_SHA"
options:
logging: CLOUD_LOGGING_ONLY