From 412ed1799b85094b721fbdaaad2836bed8e8d238 Mon Sep 17 00:00:00 2001 From: petechd Date: Wed, 4 Aug 2021 11:46:37 +0100 Subject: [PATCH 1/2] Add image tag from file and README mention --- ci/README.md | 1 + ci/deploy.yaml | 5 ++++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/ci/README.md b/ci/README.md index 81a6642b..008a1526 100644 --- a/ci/README.md +++ b/ci/README.md @@ -5,6 +5,7 @@ To deploy this application with Concourse, you must be logged in to a Concourse --- Make sure the required [environment variables](../README.md#environment-variables) are set. +IMAGE_TAG can be passed as an environment variable or as a file input located at `./image-tag/tag`. To deploy the app via Concourse, use the following task command: diff --git a/ci/deploy.yaml b/ci/deploy.yaml index a230d994..e09bb310 100644 --- a/ci/deploy.yaml +++ b/ci/deploy.yaml @@ -26,6 +26,9 @@ run: EOL gcloud auth activate-service-account --key-file $GOOGLE_APPLICATION_CREDENTIALS - + FILE=./image-tag/tag + if [[ -f "${FILE}" ]]; then + export IMAGE_TAG=`cat "$FILE"` + fi cd eq-questionnaire-launcher ./ci/deploy_app.sh From 45625479411c1a1a688a24eb440a69bebfa34d56 Mon Sep 17 00:00:00 2001 From: petechd Date: Wed, 4 Aug 2021 11:53:18 +0100 Subject: [PATCH 2/2] Add input --- ci/deploy.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ci/deploy.yaml b/ci/deploy.yaml index e09bb310..091cee41 100644 --- a/ci/deploy.yaml +++ b/ci/deploy.yaml @@ -15,6 +15,8 @@ params: MAX_INSTANCES: inputs: - name: eq-questionnaire-launcher + - name: image-tag + optional: true run: path: bash args: