Execute jobs only on master branch, better tags for images
Some checks failed
Invidious CI / build (push) Has been cancelled
Some checks failed
Invidious CI / build (push) Has been cancelled
This commit is contained in:
parent
01bfa94f84
commit
e9fbc17ac1
1 changed files with 12 additions and 1 deletions
|
@ -6,6 +6,8 @@ on:
|
|||
schedule:
|
||||
- cron: '0 7 * * 0'
|
||||
push:
|
||||
branches:
|
||||
- "master"
|
||||
|
||||
jobs:
|
||||
build:
|
||||
|
@ -24,12 +26,21 @@ jobs:
|
|||
username: ${{ secrets.USERNAME }}
|
||||
password: ${{ secrets.TOKEN }}
|
||||
|
||||
- name: Docker meta
|
||||
id: meta
|
||||
uses: https://github.com/docker/metadata-action@v5
|
||||
with:
|
||||
images: git.nadeko.net/fijxu/invidious
|
||||
tags: |
|
||||
type=sha,format=short,prefix={{date 'YYYY.MM.DD'}}-,enable=${{ github.ref == format('refs/heads/{0}', 'master') }}
|
||||
type=raw,value=latest,enable=${{ github.ref == format('refs/heads/{0}', 'master') }}
|
||||
|
||||
- uses: https://code.forgejo.org/docker/build-push-action@v5
|
||||
name: Build images
|
||||
with:
|
||||
context: .
|
||||
file: docker/Dockerfile
|
||||
tags: git.nadeko.net/fijxu/invidious:latest
|
||||
tags: ${{ steps.meta.outputs.tags }}
|
||||
platforms: linux/amd64
|
||||
push: true
|
||||
build-args: |
|
||||
|
|
Loading…
Reference in a new issue