Disable linux/arm64 builds for non-default branch
This commit is contained in:
parent
5543c68e61
commit
5075571c1c
1 changed files with 9 additions and 1 deletions
10
.github/workflows/main.yml
vendored
10
.github/workflows/main.yml
vendored
|
|
@ -45,7 +45,6 @@ on:
|
|||
env:
|
||||
DOCKERHUB_SLUG: arabcoders/ytptube
|
||||
GHCR_SLUG: ghcr.io/arabcoders/ytptube
|
||||
PLATFORMS: linux/amd64,linux/arm64
|
||||
PNPM_VERSION: 10
|
||||
NODE_VERSION: 20
|
||||
|
||||
|
|
@ -132,6 +131,15 @@ jobs:
|
|||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
|
||||
- name: Set Platforms Based on Branch
|
||||
id: set_platforms
|
||||
run: |
|
||||
if [ "${GITHUB_REF}" == "refs/heads/${{ github.repository.default_branch }}" ]; then
|
||||
echo "PLATFORMS=linux/amd64,linux/arm64" >> $GITHUB_ENV
|
||||
else
|
||||
echo "PLATFORMS=linux/amd64" >> $GITHUB_ENV
|
||||
fi
|
||||
|
||||
- name: Docker meta
|
||||
id: meta
|
||||
uses: docker/metadata-action@v5
|
||||
|
|
|
|||
Loading…
Reference in a new issue