Skip to content

exaile-testimg CI

exaile-testimg CI #331

Workflow file for this run

name: exaile-testimg CI
on:
push:
pull_request:
schedule:
- cron: '41 5 * * *'
workflow_dispatch: # Allow running manually
jobs:
build:
strategy:
matrix:
include:
## These are generally the oldest and newest releases that contain
## Python >= 3.8 and are still maintained
# https://en.wikipedia.org/wiki/Debian_version_history#Release_table
# https://packages.debian.org/bullseye/python3
- name: debian
version: 11
- name: debian
version: stable
# https://en.wikipedia.org/wiki/Fedora_(operating_system)#Releases
# https://mdapi.fedoraproject.org/f37/pkg/python3
- name: fedora
version: 37
- name: fedora
version: latest
# https://en.wikipedia.org/wiki/Ubuntu#Releases
# https://packages.ubuntu.com/focal/python3
- name: ubuntu
version: 20.04
- name: ubuntu
version: rolling
runs-on: ubuntu-latest
env:
IMAGE: ghcr.io/${{ github.repository_owner }}/exaile-testimg:${{ matrix.name }}-${{ matrix.version }}
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Login
run: printf '%s' '${{ secrets.GITHUB_TOKEN }}' | docker login ghcr.io -u '${{ github.actor }}' --password-stdin
- name: Build
run: >
docker buildx build
-f 'Dockerfile.${{ matrix.name }}'
-t "$IMAGE"
--build-arg 'VERSION=${{ matrix.version }}'
.
- name: History
run: docker history "$IMAGE"
- name: Push
if: (github.event_name == 'push' || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch') && github.ref == 'refs/heads/master'
run: docker push "$IMAGE"