From afaf555f3c83c4dd620dec62c788b3dd71892723 Mon Sep 17 00:00:00 2001 From: Jasper Ginn Date: Sat, 6 Jan 2024 20:31:08 +0100 Subject: [PATCH] build: use push for deploy --- .github/workflows/pipeline.yaml | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/.github/workflows/pipeline.yaml b/.github/workflows/pipeline.yaml index eb47515..7f8c07d 100644 --- a/.github/workflows/pipeline.yaml +++ b/.github/workflows/pipeline.yaml @@ -53,14 +53,17 @@ jobs: runs-on: ubuntu-latest environment: production needs: build - if: always() && (needs.build.result == 'success') && (github.event_name == 'release') + if: always() && (needs.build.result == 'success') && (github.event_name == 'push') steps: - name: Checkout uses: actions/checkout@v3 - - name: 'set version (release)' + - name: 'set version (push)' run: | - VERSION=$(echo $GITHUB_REF | sed -e 's/refs\/tags\///g') - echo "VERSION=$VERSION" >> $GITHUB_ENV + echo "VERSION=$(git rev-parse --short HEAD)" >> $GITHUB_ENV + # - name: 'set version (release)' + # run: | + # VERSION=$(echo $GITHUB_REF | sed -e 's/refs\/tags\///g') + # echo "VERSION=$VERSION" >> $GITHUB_ENV - name: Setup nginx uses: cuchi/jinja2-action@v1.2.2 with: