Skip to content

Docker

Docker #221

Workflow file for this run

name: Docker
on:
workflow_dispatch:
# workflow_run:
# workflows: [Release]
# types:
# - completed
schedule:
- cron: '0 2 * * 1'
env:
REGISTRY: ghcr.io
IMAGE_NAME: ${{ github.repository }}
jobs:
build-and-push-gnu-image:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
strategy:
matrix:
python_version: ['3.8', '3.9', '3.10', '3.11', '3.12']
image_flavor: ['', '-slim']
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Log in to the Container registry
uses: docker/login-action@v1
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- uses: docker/setup-qemu-action@v2
with:
platforms: arm64
- uses: docker/setup-buildx-action@v2
- name: Build and push 1.3 image
uses: docker/build-push-action@v4
with:
context: docker
platforms: linux/amd64,linux/arm64
file: docker/Gnu.fixedv.Dockerfile
push: true
tags: ${{ env.REGISTRY }}/${{ github.repository }}:${{ matrix.python_version }}${{ matrix.image_flavor }}-1.3
build-args: |
PYTHON_IMAGE=${{ matrix.python_version }}${{ matrix.image_flavor }}
POETRY_VERSION=1.3.2-1
- name: Build and push 1.4 image
uses: docker/build-push-action@v4
with:
context: docker
platforms: linux/amd64,linux/arm64
file: docker/Gnu.fixedv.Dockerfile
push: true
tags: ${{ env.REGISTRY }}/${{ github.repository }}:${{ matrix.python_version }}${{ matrix.image_flavor }}-1.4
build-args: |
PYTHON_IMAGE=${{ matrix.python_version }}${{ matrix.image_flavor }}
POETRY_VERSION=1.4.2-1
- name: Build and push 1.5 image
uses: docker/build-push-action@v4
with:
context: docker
platforms: linux/amd64,linux/arm64
file: docker/Gnu.fixedv.Dockerfile
push: true
tags: ${{ env.REGISTRY }}/${{ github.repository }}:${{ matrix.python_version }}${{ matrix.image_flavor }}-1.5
build-args: |
PYTHON_IMAGE=${{ matrix.python_version }}${{ matrix.image_flavor }}
POETRY_VERSION=1.5.1-1
- name: Build and push 1.6 image
uses: docker/build-push-action@v4
with:
context: docker
platforms: linux/amd64,linux/arm64
file: docker/Gnu.fixedv.Dockerfile
push: true
tags: ${{ env.REGISTRY }}/${{ github.repository }}:${{ matrix.python_version }}${{ matrix.image_flavor }}-1.6
build-args: |
PYTHON_IMAGE=${{ matrix.python_version }}${{ matrix.image_flavor }}
POETRY_VERSION=1.6.0-1
- name: Build and push 1.7 image
uses: docker/build-push-action@v4
with:
context: docker
platforms: linux/amd64,linux/arm64
file: docker/Gnu.fixedv.Dockerfile
push: true
tags: ${{ env.REGISTRY }}/${{ github.repository }}:${{ matrix.python_version }}${{ matrix.image_flavor }}-1.7
build-args: |
PYTHON_IMAGE=${{ matrix.python_version }}${{ matrix.image_flavor }}
POETRY_VERSION=1.7.1-1
- name: Build and push Docker image
uses: docker/build-push-action@v4
with:
context: docker
platforms: linux/amd64,linux/arm64
file: docker/Gnu.Dockerfile
push: true
tags: ${{ env.REGISTRY }}/${{ github.repository }}:${{ matrix.python_version }}${{ matrix.image_flavor }}
build-args: |
PYTHON_IMAGE=${{ matrix.python_version }}${{ matrix.image_flavor }}
GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }}
build-and-push-musl-image:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
strategy:
fail-fast: false
matrix:
python_version: ['3.8', '3.9', '3.10', '3.11', '3.12']
image_flavor: ['-alpine']
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Log in to the Container registry
uses: docker/login-action@v1
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push 1.3 image
uses: docker/build-push-action@v4
with:
context: docker
file: docker/Alpine.fixedv.Dockerfile
push: true
tags: ${{ env.REGISTRY }}/${{ github.repository }}:${{ matrix.python_version }}${{ matrix.image_flavor }}-1.3
build-args: |
PYTHON_IMAGE=${{ matrix.python_version }}${{ matrix.image_flavor }}
POETRY_VERSION=1.3.2-1
- name: Build and push 1.4 image
uses: docker/build-push-action@v4
with:
context: docker
file: docker/Alpine.fixedv.Dockerfile
push: true
tags: ${{ env.REGISTRY }}/${{ github.repository }}:${{ matrix.python_version }}${{ matrix.image_flavor }}-1.4
build-args: |
PYTHON_IMAGE=${{ matrix.python_version }}${{ matrix.image_flavor }}
POETRY_VERSION=1.4.2-1
- name: Build and push 1.5 image
uses: docker/build-push-action@v4
with:
context: docker
file: docker/Alpine.fixedv.Dockerfile
push: true
tags: ${{ env.REGISTRY }}/${{ github.repository }}:${{ matrix.python_version }}${{ matrix.image_flavor }}-1.5
build-args: |
PYTHON_IMAGE=${{ matrix.python_version }}${{ matrix.image_flavor }}
POETRY_VERSION=1.5.1-1
- name: Build and push 1.6 image
uses: docker/build-push-action@v4
with:
context: docker
file: docker/Alpine.fixedv.Dockerfile
push: true
tags: ${{ env.REGISTRY }}/${{ github.repository }}:${{ matrix.python_version }}${{ matrix.image_flavor }}-1.6
build-args: |
PYTHON_IMAGE=${{ matrix.python_version }}${{ matrix.image_flavor }}
POETRY_VERSION=1.6.0-1
- name: Build and push 1.7 image
uses: docker/build-push-action@v4
with:
context: docker
file: docker/Alpine.fixedv.Dockerfile
push: true
tags: ${{ env.REGISTRY }}/${{ github.repository }}:${{ matrix.python_version }}${{ matrix.image_flavor }}-1.7
build-args: |
PYTHON_IMAGE=${{ matrix.python_version }}${{ matrix.image_flavor }}
POETRY_VERSION=1.7.1-1
- name: Build and push Docker image
uses: docker/build-push-action@v4
with:
context: docker
file: docker/Alpine.Dockerfile
push: true
tags: ${{ env.REGISTRY }}/${{ github.repository }}:${{ matrix.python_version }}${{ matrix.image_flavor }}
build-args: |
PYTHON_IMAGE=${{ matrix.python_version }}${{ matrix.image_flavor }}
GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }}