Skip to content

Rebuild images once a month #14

Rebuild images once a month

Rebuild images once a month #14

Workflow file for this run

name: Build dunst CI images

Check failure on line 1 in .github/workflows/main.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/main.yml

Invalid workflow file

`schedule` accepts a list of one or more maps with the `cron` key set
# Run only when merged onto master or once a month in order to get latest
# packages for each distribution.
on:
schedule:
cron: "42 3 15 * *"
push:
branches: [ 'master' ]
workflow_dispatch:
env:
REGISTRY: ghcr.io
IMAGE_NAME: ${{ github.repository }}
jobs:
build-and-push-image:
runs-on: ubuntu-latest
strategy:
matrix:
distro:
- alpine
- archlinux
- debian-bookworm
- debian-bullseye
- debian-buster
- fedora
- misc-doxygen
- ubuntu-focal
- ubuntu-jammy
# We need to push to the registry
permissions:
contents: read
packages: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Log in to the Container registry
uses: docker/[email protected]
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
# Default metadata action step.
# Will add some "org.opencontainers.*"-labels with useful descriptions
# However the tags are totally unusable for our case
- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/[email protected]
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
- name: Build and push Docker image
uses: docker/[email protected]
with:
context: ci
file: ci/Dockerfile.${{ matrix.distro }}
push: true
tags: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ matrix.distro }}
labels: ${{ steps.meta.outputs.labels }}