File tree Expand file tree Collapse file tree 1 file changed +3
-6
lines changed Expand file tree Collapse file tree 1 file changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -39,26 +39,23 @@ jobs:
39
39
type=semver,pattern=v{{version}}
40
40
type=semver,pattern=v{{major}}.{{minor}}
41
41
42
- - name : Don't push to registry if this is a PR
43
- if : github.event_name == 'pull_request'
44
- run : |
45
- echo "Not pushing the image to any container registry as this workflow is running on a pull request"
46
- exit 0
47
-
48
42
- name : Log in to DockerHub
43
+ if : github.event_name != 'pull_request'
49
44
uses : docker/login-action@v2
50
45
with :
51
46
username : ${{ secrets.DOCKER_HUB_USERNAME }}
52
47
password : ${{ secrets.DOCKER_HUB_TOKEN }}
53
48
54
49
- name : Log in to GHCR
50
+ if : github.event_name != 'pull_request'
55
51
uses : docker/login-action@v2
56
52
with :
57
53
registry : ghcr.io
58
54
username : ${{ github.repository_owner }}
59
55
password : ${{ secrets.GITHUB_TOKEN }}
60
56
61
57
- name : Build and push all platforms
58
+ if : github.event_name != 'pull_request'
62
59
uses : docker/build-push-action@v4
63
60
with :
64
61
push : true
You can’t perform that action at this time.
0 commit comments