mirror of
https://github.com/meeb/tubesync.git
synced 2025-06-23 13:36:35 +00:00
The workflow should work for forks also
This commit is contained in:
parent
a904d60ad8
commit
4bc510bdad
10
.github/workflows/ci.yaml
vendored
10
.github/workflows/ci.yaml
vendored
@ -34,7 +34,10 @@ jobs:
|
|||||||
- name: Run Django tests
|
- name: Run Django tests
|
||||||
run: cd tubesync && python3 manage.py test --verbosity=2
|
run: cd tubesync && python3 manage.py test --verbosity=2
|
||||||
containerise:
|
containerise:
|
||||||
|
if: ${{ always() }}
|
||||||
|
needs: test
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
timeout-minutes: 120
|
||||||
steps:
|
steps:
|
||||||
- name: Set up QEMU
|
- name: Set up QEMU
|
||||||
uses: docker/setup-qemu-action@v3
|
uses: docker/setup-qemu-action@v3
|
||||||
@ -42,13 +45,18 @@ jobs:
|
|||||||
id: buildx
|
id: buildx
|
||||||
uses: docker/setup-buildx-action@v3
|
uses: docker/setup-buildx-action@v3
|
||||||
- name: Log into GitHub Container Registry
|
- name: Log into GitHub Container Registry
|
||||||
run: echo "${{ secrets.REGISTRY_ACCESS_TOKEN }}" | docker login https://ghcr.io -u ${{ github.actor }} --password-stdin
|
env:
|
||||||
|
DOCKER_REGISTRY: https://ghcr.io
|
||||||
|
DOCKER_USERNAME: ${{ github.actor }}
|
||||||
|
DOCKER_TOKEN: ${{ 'meeb' == github.repository_owner && secrets.REGISTRY_ACCESS_TOKEN || secrets.GITHUB_TOKEN }}
|
||||||
|
run: echo '${{ env.DOCKER_TOKEN }}' | docker login --password-stdin --username '${{ env.DOCKER_USERNAME }}' '${{ env.DOCKER_REGISTRY }}'
|
||||||
- name: Lowercase github username for ghcr
|
- name: Lowercase github username for ghcr
|
||||||
id: string
|
id: string
|
||||||
uses: ASzc/change-string-case-action@v6
|
uses: ASzc/change-string-case-action@v6
|
||||||
with:
|
with:
|
||||||
string: ${{ github.actor }}
|
string: ${{ github.actor }}
|
||||||
- name: Build and push
|
- name: Build and push
|
||||||
|
timeout-minutes: 60
|
||||||
uses: docker/build-push-action@v6
|
uses: docker/build-push-action@v6
|
||||||
with:
|
with:
|
||||||
platforms: linux/amd64,linux/arm64
|
platforms: linux/amd64,linux/arm64
|
||||||
|
Loading…
Reference in New Issue
Block a user