From eff28d62cbb192c4e479ed3ee7b8e99e5c6c12fa Mon Sep 17 00:00:00 2001 From: Florian Necas Date: Mon, 27 Nov 2023 08:35:23 +0100 Subject: [PATCH] feat: build alpha with branch --- .github/workflows/georchestra-gn4.yml | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/.github/workflows/georchestra-gn4.yml b/.github/workflows/georchestra-gn4.yml index 2aa7a701c1..48b18159d6 100644 --- a/.github/workflows/georchestra-gn4.yml +++ b/.github/workflows/georchestra-gn4.yml @@ -3,12 +3,12 @@ name: Building georchestra-geonetwork4 artifacts on: push: branches: - - georchestra-gn4.2.x + - georchestra-gn-4.2.6-build pull_request: workflow_dispatch: env: - DOCKER_TAG: 4.2.x + DOCKER_TAG: 4.2.6-alpha jobs: build: @@ -62,26 +62,20 @@ jobs: -DdockerImageName=georchestra/geonetwork:${DOCKER_TAG} -DskipTests - name: "publish the webapp as artifact" - if: github.repository == 'georchestra/geonetwork' && github.actor != 'dependabot[bot]' && github.ref == 'refs/heads/georchestra-gn4.2.x' && github.event_name != 'pull_request' + if: github.repository == 'georchestra/geonetwork' && github.actor != 'dependabot[bot]' && github.ref == 'refs/heads/georchestra-gn-4.2.6-build' uses: actions/upload-artifact@v1 with: name: geonetwork.war path: web/target/geonetwork.war - name: "Login onto docker-hub" - if: github.repository == 'georchestra/geonetwork' && github.actor != 'dependabot[bot]' && github.ref == 'refs/heads/georchestra-gn4.2.x' && github.event_name != 'pull_request' + if: github.repository == 'georchestra/geonetwork' && github.actor != 'dependabot[bot]' && github.ref == 'refs/heads/georchestra-gn-4.2.6-build' uses: docker/login-action@v1 with: username: '${{ secrets.DOCKER_HUB_USERNAME }}' password: '${{ secrets.DOCKER_HUB_PASSWORD }}' - name: "Pushing branch image to docker-hub" - if: github.repository == 'georchestra/geonetwork' && github.actor != 'dependabot[bot]' && github.ref == 'refs/heads/georchestra-gn4.2.x' && github.event_name != 'pull_request' + if: github.repository == 'georchestra/geonetwork' && github.actor != 'dependabot[bot]' && github.ref == 'refs/heads/georchestra-gn-4.2.6-build' run: | docker push georchestra/geonetwork:${DOCKER_TAG} - - - name: "Pushing latest image to docker-hub" - if: github.repository == 'georchestra/geonetwork' && github.actor != 'dependabot[bot]' && github.ref == 'refs/heads/georchestra-gn4.2.x' && github.event_name != 'pull_request' - run: | - docker tag georchestra/geonetwork:${DOCKER_TAG} georchestra/geonetwork:latest - docker push georchestra/geonetwork:latest