|
2 | 2 | - name: docker
|
3 | 3 | id: build_and_push
|
4 | 4 | entrypoint: sh
|
5 |
| - args: |
6 |
| - - '-c' |
| 5 | + args: |
| 6 | + - "-c" |
7 | 7 | - |
|
8 | 8 | if [ $_ENV = "staging" ]; then
|
9 |
| - docker build -t "eu.gcr.io/ons-eqbs-images/eq-publisher:$SHORT_SHA" . |
10 |
| - docker push "eu.gcr.io/ons-eqbs-images/eq-publisher:$SHORT_SHA" |
| 9 | + docker build -t "$_EQ_PUBLISHER_IMAGE_REPO:$SHORT_SHA" . |
| 10 | + docker push "$_EQ_PUBLISHER_IMAGE_REPO:$SHORT_SHA" |
11 | 11 | else
|
12 | 12 | echo "*************************************************************"
|
13 | 13 | echo "* Build not required *"
|
14 | 14 | echo "*************************************************************"
|
15 | 15 | fi
|
16 | 16 |
|
17 |
| - - name: 'gcr.io/google.com/cloudsdktool/cloud-sdk:alpine' |
| 17 | + - name: "gcr.io/google.com/cloudsdktool/cloud-sdk:alpine" |
18 | 18 | id: tag release
|
19 | 19 | entrypoint: /bin/bash
|
20 | 20 | args:
|
21 |
| - - '-c' |
| 21 | + - "-c" |
22 | 22 | - |
|
23 | 23 | if [ $_ENV = "preprod" ]; then
|
24 | 24 | gcloud container images add-tag \
|
25 |
| - eu.gcr.io/ons-eqbs-images/eq-publisher:$SHORT_SHA \ |
26 |
| - eu.gcr.io/ons-eqbs-images/eq-publisher:$TAG_NAME |
| 25 | + $_EQ_PUBLISHER_IMAGE_REPO:$SHORT_SHA \ |
| 26 | + $_EQ_PUBLISHER_IMAGE_REPO:$TAG_NAME |
27 | 27 | else
|
28 | 28 | echo "*************************************************************"
|
29 | 29 | echo "* Tagging not required *"
|
30 | 30 | echo "*************************************************************"
|
31 | 31 | fi
|
32 | 32 |
|
33 |
| - - name: 'gcr.io/google.com/cloudsdktool/cloud-sdk:alpine' |
| 33 | + - name: "gcr.io/google.com/cloudsdktool/cloud-sdk:alpine" |
34 | 34 | id: deploy
|
35 | 35 | entrypoint: sh
|
36 | 36 | args:
|
37 |
| - - '-c' |
| 37 | + - "-c" |
38 | 38 | - |
|
39 | 39 | if [ $_ENV = "staging" ]; then
|
40 | 40 | gcloud run deploy eq-publisher \
|
41 |
| - --image "eu.gcr.io/ons-eqbs-images/eq-publisher:$SHORT_SHA" \ |
| 41 | + --image "$_EQ_PUBLISHER_IMAGE_REPO:$SHORT_SHA" \ |
42 | 42 | --region europe-west2 \
|
43 | 43 | --platform managed
|
44 | 44 | else
|
45 | 45 | gcloud run deploy eq-publisher \
|
46 |
| - --image "eu.gcr.io/ons-eqbs-images/eq-publisher:$TAG_NAME" \ |
| 46 | + --image "$_EQ_PUBLISHER_IMAGE_REPO:$TAG_NAME" \ |
47 | 47 | --region europe-west2 \
|
48 | 48 | --platform managed
|
49 | 49 | fi
|
0 commit comments