fix: use _WH_URL with underscore prefix - valid Cloud Build substitution key
This commit is contained in:
parent
aa76e9ab4c
commit
032cf19f24
|
|
@ -62,12 +62,12 @@ steps:
|
|||
args:
|
||||
- '-c'
|
||||
- |
|
||||
WH_URL=$(gcloud secrets versions access latest \
|
||||
_WH_URL=$(gcloud secrets versions access latest \
|
||||
--secret=webhook-url \
|
||||
--project=${PROJECT_ID} 2>/dev/null || echo "")
|
||||
if [[ -n "$WH_URL" ]]; then
|
||||
if [[ -n "$_WH_URL" ]]; then
|
||||
MSG="✅ *OSVauco Deploy fullført*\nCommit: \`$COMMIT_SHA\`\nService: \`${_CLOUD_RUN_SERVICE}\`\nRegion: \`${_REGION}\`"
|
||||
curl -s -X POST "$WH_URL" \
|
||||
curl -s -X POST "$_WH_URL" \
|
||||
-H 'Content-Type: application/json' \
|
||||
-d "{\"text\": \"$MSG\"}" || true
|
||||
echo "✓ Deploy-notifikasjon sendt"
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user