diff --git a/.github/workflows/cicd_deploy.yml b/.github/workflows/cicd_deploy.yml index b913dce..f26f17c 100644 --- a/.github/workflows/cicd_deploy.yml +++ b/.github/workflows/cicd_deploy.yml @@ -5,7 +5,6 @@ on: # Also run when the pull request merges (which generates a push) # So that we can tag the docker image appropriately. push: - branches: [ "master" ] tags: [ 'v*.*.*' ] env: @@ -39,6 +38,16 @@ jobs: ${{ env.TEST_TAG }} python -m pytest ./test -s --log-cli-level DEBUG + # Login against a Docker registry except on PR + # https://github.com/docker/login-action + - name: Log into registry ${{ env.REGISTRY }} + if: github.event_name != 'pull_request' + uses: docker/login-action@v2 + with: + registry: ${{ env.REGISTRY }} + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + # Extract metadata (tags, labels) for Docker # https://github.com/docker/metadata-action - name: Extract Docker metadata diff --git a/.github/workflows/cicd_full.yml b/.github/workflows/cicd_full.yml index 6952358..a4071f9 100644 --- a/.github/workflows/cicd_full.yml +++ b/.github/workflows/cicd_full.yml @@ -45,9 +45,6 @@ jobs: test_local: runs-on: ubuntu-latest - environment: - name: pypi - url: https://pypi.org/p/ign-pdal-tools permissions: contents: read packages: write