From 9d5cd29a4b6a5e076cc1e0bb982e00be4f9fd834 Mon Sep 17 00:00:00 2001 From: Josh Date: Thu, 31 Jul 2025 17:04:31 +0000 Subject: [PATCH] pipeline build v42. correct reversion v2 --- .woodpecker.yml | 31 +++++++++++++------------------ 1 file changed, 13 insertions(+), 18 deletions(-) diff --git a/.woodpecker.yml b/.woodpecker.yml index 84ba478..742f498 100644 --- a/.woodpecker.yml +++ b/.woodpecker.yml @@ -1,31 +1,26 @@ ---- -kind: pipeline -type: docker -name: ssh-test - steps: - name: ssh-test image: google/cloud-sdk:latest entrypoint: - bash - -c - - > - set -euo pipefail; + - | + set -euo pipefail - mkdir -p ~/.ssh; + mkdir -p ~/.ssh # ── Inject known-hosts and SSH key ─────────────────────────────── gcloud secrets versions access latest \ --secret=STAGING_KNOWN_HOSTS --project=aptivaai-dev \ - | base64 -d > ~/.ssh/known_hosts; - chmod 644 ~/.ssh/known_hosts; + | base64 -d > ~/.ssh/known_hosts + chmod 644 ~/.ssh/known_hosts gcloud secrets versions access latest \ --secret=STAGING_SSH_KEY --project=aptivaai-dev \ - | base64 -d > ~/.ssh/id_ed25519; - chmod 600 ~/.ssh/id_ed25519; + | base64 -d > ~/.ssh/id_ed25519 + chmod 600 ~/.ssh/id_ed25519 - echo "🔑 SSH prerequisites installed"; + echo "🔑 SSH prerequisites installed" # ── SSH into staging and deploy ────────────────────────────────── ssh -o StrictHostKeyChecking=yes \ @@ -39,12 +34,12 @@ steps: echo "IMG_TAG = $IMG_TAG"; \ sudo --preserve-env=IMG_TAG docker compose pull; \ sudo --preserve-env=IMG_TAG docker compose up -d --force-recreate --remove-orphans; \ - echo "✅ Staging stack refreshed with tag $IMG_TAG"' + echo "✅ Staging stack refreshed with tag $IMG_TAG"' + secrets: - STAGING_SSH_KEY - STAGING_KNOWN_HOSTS - - IMG_TAG -when: - event: - - push + when: + event: + - push \ No newline at end of file