concourse/tasks/gcloud-publish-image.yaml (16 lines of code) (raw):

--- platform: linux image_resource: type: registry-image source: repository: google/cloud-sdk tag: alpine inputs: - name: compute-image-tools run: path: sh args: - -exc - | wf=$(sed 's/\"/\\"/g' ./compute-image-tools/daisy_workflows/build-publish/((wf)) | tr -d '\n') gcloud pubsub topics publish "((topic))" --message "{\"type\": \"insertImage\", \"request\": {\"image_name\": \"((image_name))\", \"gcs_image_path\": \"((gcs_image_path))\", \"image_publish_template\": \"${wf}\", \"source_version\": \"((source_version))\", \"publish_version\": \"((publish_version))\", \"release_notes\": \"((release_notes))\"}}"