From e6d663535c3ee2a67c5c223b10781b604a4c304f Mon Sep 17 00:00:00 2001 From: Andreas Hnida Date: Thu, 18 Apr 2024 09:02:15 +0200 Subject: [PATCH] Refactor deploy steps logic in pipeline-test.yaml file --- .gitea/workflows/pipeline-test.yaml | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/.gitea/workflows/pipeline-test.yaml b/.gitea/workflows/pipeline-test.yaml index 1b94864..7916ac5 100644 --- a/.gitea/workflows/pipeline-test.yaml +++ b/.gitea/workflows/pipeline-test.yaml @@ -25,6 +25,9 @@ jobs: file: 'hugo.toml' field: 'environment' + - name: Echo environment + run: echo "Environment is ${{ steps.read_toml.outputs.environment }}" + # - name: Set up Go # uses: actions/setup-go@v5.0.0 # with: @@ -76,17 +79,11 @@ jobs: - name: Deploy to Development if: steps.read_toml.outputs.environment == 'development' - run: | - rsync -avz --delete ./public/ verua.info@verua.info:/preview.verua.info/ - env: - RSYNC_RSH: 'ssh -p 2121 -o StrictHostKeyChecking=no' + run: echo "Running steps for Development Environment" - name: Deploy to Production if: steps.read_toml.outputs.environment == 'production' - run: | - rsync -avz --delete ./public/ verua.info@verua.info:/httpdocs/ - env: - RSYNC_RSH: 'ssh -p 2121 -o StrictHostKeyChecking=no' + run: echo "Running steps for Production Environment" # - name: Deploy to Development # if: env.myEnv_env == 'development'