commit: 6f21df87717f8a871b4ae292faff107bde9d214d
Author: John Helmert III <ajak <AT> gentoo <DOT> org>
AuthorDate: Thu Feb 8 04:59:57 2024 +0000
Commit: John Helmert III <ajak <AT> gentoo <DOT> org>
CommitDate: Thu Feb 8 05:21:07 2024 +0000
URL: https://gitweb.gentoo.org/proj/docker-images.git/commit/?id=6f21df87
actions: limit pushes to master branch
We don't want these steps to run on branches in this repository, even
if they're in a pull request to the master branch. We only want pushes
to happen from the master branch.
Closes: !137
Signed-off-by: John Helmert III <ajak <AT> gentoo.org>
.github/actions/container_build/action.yml | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/.github/actions/container_build/action.yml
b/.github/actions/container_build/action.yml
index f4f2378..fc2b9b9 100644
--- a/.github/actions/container_build/action.yml
+++ b/.github/actions/container_build/action.yml
@@ -35,14 +35,14 @@ runs:
- name: Login to DockerHub
uses: docker/login-action@v2
if: |
- github.repository_owner == 'gentoo' &&
+ github.ref_name == 'master' && github.repository_owner == 'gentoo' &&
(github.event_name == 'schedule' || github.event_name == 'push')
with:
username: ${{ inputs.dockerhub_username }}
password: ${{ inputs.dockerhub_password }}
- name: Push image
if: |
- github.repository_owner == 'gentoo' &&
+ github.ref_name == 'master' && github.repository_owner == 'gentoo' &&
(github.event_name == 'schedule' || github.event_name == 'push')
shell: bash
env: