mirror of
https://github.com/docker/metadata-action.git
synced 2025-06-24 03:37:59 +02:00
Allow to templatize schedule tag (#1)
Co-authored-by: CrazyMax <crazy-max@users.noreply.github.com>
This commit is contained in:
27
.github/workflows/ci.yml
vendored
27
.github/workflows/ci.yml
vendored
@ -2,7 +2,7 @@ name: ci
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: '0 10 * * 0' # everyday sunday at 10am
|
||||
- cron: '0 * * * *' # every hours
|
||||
push:
|
||||
branches:
|
||||
- '**'
|
||||
@ -22,7 +22,6 @@ jobs:
|
||||
uses: actions/checkout@v2.3.3
|
||||
-
|
||||
name: Docker meta
|
||||
id: docker_meta
|
||||
uses: ./
|
||||
with:
|
||||
images: |
|
||||
@ -30,6 +29,30 @@ jobs:
|
||||
ghcr.io/name/app
|
||||
tag-sha: true
|
||||
|
||||
tag-schedule:
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
tag-schedule:
|
||||
- ""
|
||||
- "cron-{{date 'YYYYMMDD'}}"
|
||||
- "{{date 'YYYYMMDD-HHmmss'}}"
|
||||
- "schedule"
|
||||
steps:
|
||||
-
|
||||
name: Checkout
|
||||
uses: actions/checkout@v2.3.3
|
||||
-
|
||||
name: Docker meta
|
||||
uses: ./
|
||||
with:
|
||||
images: |
|
||||
${{ env.DOCKER_IMAGE }}
|
||||
ghcr.io/name/app
|
||||
tag-sha: true
|
||||
tag-schedule: ${{ matrix.tag-schedule }}
|
||||
|
||||
docker-push:
|
||||
runs-on: ubuntu-latest
|
||||
services:
|
||||
|
Reference in New Issue
Block a user