Skip to content

Commit

Permalink
Not skip docker login on master (#2289)
Browse files Browse the repository at this point in the history
* skip polkadot build on master

* not skip login in master

* typo

* docker login only on push and internal PRs

* missing ||

* not skip build on master
  • Loading branch information
librelois authored May 11, 2023
1 parent 504ac0e commit 1a710fc
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -214,8 +214,12 @@ jobs:
with:
ref: ${{ needs.set-tags.outputs.git_ref }}
- name: Login to DockerHub
# The if must stay on this step (because this job must not be skipped)
if: ${{ github.event.pull_request.head.repo.full_name == github.repository }}
# We should make sure that external PRs can't login to docker,
# but the check to detect if a PR is "external" not work when
# this workflow is trigerred by a push.
if: |
github.event_name == 'push' ||
github.event.pull_request.head.repo.full_name == github.repository
uses: docker/[email protected]
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
Expand Down

0 comments on commit 1a710fc

Please sign in to comment.