From 0e05560cb32d15addafa41ec15a4cce6c4dbd89b Mon Sep 17 00:00:00 2001 From: Hadeed Ahmad Date: Wed, 24 Apr 2024 06:58:49 +0500 Subject: [PATCH] Add conditions --- .woodpecker.yaml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.woodpecker.yaml b/.woodpecker.yaml index 7028fba..2193abe 100644 --- a/.woodpecker.yaml +++ b/.woodpecker.yaml @@ -12,5 +12,8 @@ steps: - echo "$SSH_STAGING_KEY" > ~/.ssh/staging.key - chmod 600 ~/.ssh/staging.key - ssh -i ~/.ssh/staging.key -p $${PORT} $${USER}@$${HOST} "rm -rf /srv/hadeedahmad-xyz" - - scp -ri ~/.ssh/staging.key -P $${PORT} . $${USER}@$${HOST}:/srv/hadeedahmad-xyz + - scp -ri ~/.ssh/staging.key -P $${PORT} * $${USER}@$${HOST}:/srv/hadeedahmad-xyz secrets: [ SSH_STAGING_KEY ] + when: + - event: push + branch: main