diff options
author | John Helmert III <ajak@gentoo.org> | 2024-02-07 20:59:57 -0800 |
---|---|---|
committer | John Helmert III <ajak@gentoo.org> | 2024-02-07 21:21:07 -0800 |
commit | 6f21df87717f8a871b4ae292faff107bde9d214d (patch) | |
tree | 8fda64aa1b41864dff86705bcfbe108fcb2a71c4 | |
parent | actions: also push to Dockerhub on push (diff) | |
download | docker-images-6f21df87717f8a871b4ae292faff107bde9d214d.tar.gz docker-images-6f21df87717f8a871b4ae292faff107bde9d214d.tar.bz2 docker-images-6f21df87717f8a871b4ae292faff107bde9d214d.zip |
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@gentoo.org>
-rw-r--r-- | .github/actions/container_build/action.yml | 4 |
1 files 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: |