From a651848f48d659b93d9b02e51c85490e863c11c8 Mon Sep 17 00:00:00 2001 From: admin Date: Sun, 21 Jun 2026 22:20:42 -0700 Subject: [PATCH] Fix provision-secrets: check for yaml changes before scp to avoid failure on non-stack commits --- .woodpecker.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.woodpecker.yml b/.woodpecker.yml index 519026d..9e1783f 100644 --- a/.woodpecker.yml +++ b/.woodpecker.yml @@ -24,10 +24,12 @@ steps: - echo "$SSH_KEY" | base64 -d > ~/.ssh/id_rsa - chmod 600 ~/.ssh/id_rsa - ssh-keyscan -H 192.168.4.32 >> ~/.ssh/known_hosts 2>/dev/null + - | + YAML_FILES=$(echo "${CI_COMMIT_CHANGED_FILES}" | tr ',' '\n' | grep '\.yaml$' || true) + [ -z "$YAML_FILES" ] && echo "No stack yaml files changed, skipping" && exit 0 - scp -o StrictHostKeyChecking=no deploy/create-secrets.sh root@192.168.4.32:/tmp/cs.sh - | YAML_FILES=$(echo "${CI_COMMIT_CHANGED_FILES}" | tr ',' '\n' | grep '\.yaml$' || true) - [ -z "$YAML_FILES" ] && echo "No stacks changed" && exit 0 for f in $YAML_FILES; do STACK=$(basename "$f" .yaml) echo "Provisioning: $STACK"