sync_navidrome #21
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
on: | |
push: | |
branches: | |
- main | |
paths: | |
- .github/workflows/navidrome.yml | |
- navidrome/** | |
workflow_dispatch: | |
repository_dispatch: | |
types: | |
- sync_navidrome | |
jobs: | |
navidrome: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
submodules: true | |
- name: Login | |
uses: docker/login-action@v1 | |
with: | |
username: ${{ secrets.DOCKER_HUB_USERNAME }} | |
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }} | |
- name: Setup QEMU | |
uses: docker/setup-qemu-action@v1 | |
- name: Setup Docker | |
uses: docker/setup-buildx-action@v1 | |
- name: Build Docker | |
uses: docker/build-push-action@v2 | |
with: | |
push: true | |
context: ${{ github.job }} | |
file: ${{ github.job }}/Dockerfile | |
platforms: linux/amd64 | |
tags: ${{ secrets.DOCKER_HUB_USERNAME }}/${{ github.job }}:latest | |
cache-from: type=registry,ref=${{ secrets.DOCKER_HUB_USERNAME }}/${{ github.job }}:buildcache | |
cache-to: type=registry,ref=${{ secrets.DOCKER_HUB_USERNAME }}/${{ github.job }}:buildcache,mode=max | |
build-args: | | |
ND_VER=${{ github.event.client_payload.ND_VER || '0.54.2' }} | |
- name: Push Docker Description | |
uses: peter-evans/dockerhub-description@v2 | |
with: | |
username: ${{ secrets.DOCKER_HUB_USERNAME }} | |
password: ${{ secrets.DOCKER_HUB_PASSWORD }} | |
repository: ${{ secrets.DOCKER_HUB_USERNAME }}/${{ github.job }} | |
short-description: '使用参考 README,信息参考:https://www.dosk.win/' |