Skip to content
This repository has been archived by the owner on Jul 21, 2024. It is now read-only.

Commit

Permalink
Publishing - fix main branch name and push on tag (#249)
Browse files Browse the repository at this point in the history
  • Loading branch information
AustinShalit authored Jun 30, 2021
1 parent 02ea948 commit 27bb84d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ jobs:
version: v0.5.1
- name: Login to DockerHub
uses: docker/login-action@v1
if: ${{ github.repository_owner == 'wpilibsuite' && github.ref == 'refs/heads/master' }}
if: ${{ github.repository_owner == 'wpilibsuite' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/v')) }}
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
Expand All @@ -73,7 +73,7 @@ jobs:
- name: Base - Build and push
uses: docker/build-push-action@v2
with:
push: ${{ github.repository_owner == 'wpilibsuite' && github.ref == 'refs/heads/master' }}
push: ${{ github.repository_owner == 'wpilibsuite' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/v')) }}
context: .
tags: ${{ steps.docker_meta.outputs.tags }}
labels: ${{ steps.docker_meta.outputs.labels }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/containers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
name: Build
runs-on: ubuntu-latest
env:
push: ${{ github.repository_owner == 'wpilibsuite' && github.ref == 'refs/heads/master' }}
push: ${{ github.repository_owner == 'wpilibsuite' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/v')) }}
steps:
- uses: actions/checkout@v2
- uses: docker/setup-buildx-action@v1
Expand All @@ -17,7 +17,7 @@ jobs:

- name: Login to DockerHub
uses: docker/login-action@v1
if: ${{ github.repository_owner == 'wpilibsuite' && github.ref == 'refs/heads/master' }}
if: ${{ github.repository_owner == 'wpilibsuite' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/v')) }}
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
Expand Down

0 comments on commit 27bb84d

Please sign in to comment.