From d591813b8bc3965c4f95df4788d052344422a811 Mon Sep 17 00:00:00 2001 From: Adora Laura Kalb Date: Mon, 15 Jul 2024 10:57:49 +0200 Subject: [PATCH] update CI with yaml anchor --- .woodpecker/deploy-rsync.yaml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.woodpecker/deploy-rsync.yaml b/.woodpecker/deploy-rsync.yaml index 60b2c8a..f87b41d 100644 --- a/.woodpecker/deploy-rsync.yaml +++ b/.woodpecker/deploy-rsync.yaml @@ -2,6 +2,9 @@ when: - event: push branch: [main, staging] +variables: + - &SSH_PORT "2003" + steps: build: image: golang:1.22-bookworm @@ -22,7 +25,7 @@ steps: - RSYNC_TARGET_USER environment: - TARGET_PATH=/webroot/adora.codes - - RSYNC_TARGET_PORT=2003 + - *SSH_PORT commands: - apk add --update --no-cache openssh rsync git - mkdir -p $HOME/.ssh @@ -41,7 +44,7 @@ steps: - RSYNC_TARGET_USER environment: - TARGET_PATH=/webroot/www-staging.adora.codes - - RSYNC_TARGET_PORT=2003 + - *SSH_PORT commands: - apk add --update --no-cache openssh rsync git - mkdir -p $HOME/.ssh