diff --git a/.github/workflows/workflow.yml b/.github/workflows/workflow.yml index 1cce954..0483ddd 100644 --- a/.github/workflows/workflow.yml +++ b/.github/workflows/workflow.yml @@ -11,12 +11,19 @@ on: pull_request: +# Runs of one event and branch or tag never overlap, so an older master run +# cannot finish last and move floating tags back. A newer pending run of the +# same event replaces an older one; other events never replace each other. +concurrency: + group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.ref }} + cancel-in-progress: false + env: - PYTHON315: '3.15.1' - PYTHON314: '3.14.9' - PYTHON313: '3.13.17' - PYTHON312: '3.12.15' - PYTHON311: '3.11.17' + PYTHON315: '3.15.2' + PYTHON314: '3.14.10' + PYTHON313: '3.13.18' + PYTHON312: '3.12.16' + PYTHON311: '3.11.18' jobs: setup: @@ -89,13 +96,9 @@ jobs: password: ${{ secrets.DOCKER_PASSWORD }} - name: Push architecture image if: github.event_name == 'push' - env: - PYTHON_VER: ${{ matrix.python.version }} - ARCH: ${{ matrix.arch }} - PYTHON_DEV: ${{ matrix.dev }} - WODBY_USER_ID: ${{ matrix.user_id }} - WODBY_GROUP_ID: ${{ matrix.group_id }} - run: make push + uses: wodby/images/.github/actions/arch-image-push@2da5f02ec3dffc5cb3331152e01e3c89874b0bfe + with: + image: ${{ steps.build-image.outputs.image }} push: if: github.event_name == 'push' @@ -122,6 +125,7 @@ jobs: with: username: ${{ secrets.DOCKER_USERNAME }} password: ${{ secrets.DOCKER_PASSWORD }} + - uses: wodby/images/.github/actions/arch-image-pins@2da5f02ec3dffc5cb3331152e01e3c89874b0bfe - uses: ./.github/actions with: version: ${{ matrix.python.version }} @@ -140,7 +144,7 @@ jobs: group: image-revision-aliases-${{ github.ref }} cancel-in-progress: false steps: - - uses: wodby/images/.github/actions/image-revision-aliases@412e2d9ce29c41835ff653b0945bba72eabd9efb + - uses: wodby/images/.github/actions/image-revision-aliases@aee656b81ae84e0dca0cfdbea173057abe4a9426 with: docker_username: ${{ secrets.DOCKER_USERNAME }} docker_password: ${{ secrets.DOCKER_PASSWORD }} diff --git a/.grype.yaml b/.grype.yaml index 558b527..ad89087 100644 --- a/.grype.yaml +++ b/.grype.yaml @@ -7,3 +7,13 @@ ignore: name: python version: 3.11.17 type: binary + + # CVE-2026-119170 is a hashlib regression that only affects Python 3.14.10 with OpenSSL in FIPS + # mode. The Alpine images do not run OpenSSL in FIPS mode, and Python 3.14.11 with the fix is not + # released yet: https://github.com/python/cpython/issues/160923 + # The rule matches only 3.14.10; remove it when the images move to 3.14.11. + - vulnerability: CVE-2026-119170 + package: + name: python + version: 3.14.10 + type: binary diff --git a/Makefile b/Makefile index 9e6ace4..26e2bd8 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,6 @@ -include env_make -PYTHON_VER ?= 3.15.1 +PYTHON_VER ?= 3.15.2 PYTHON_VER_MINOR := $(shell v='$(PYTHON_VER)'; echo "$${v%.*}") REPO = wodby/python @@ -79,10 +79,15 @@ buildx-push: --build-arg WODBY_GROUP_ID=$(WODBY_GROUP_ID) \ ./ +# CI combines the exact architecture images this workflow run pushed; see +# wodby/images arch-image-pins. Per-architecture tags are shared by every run, +# so an overlapping run may already have replaced one of them. +arch-image = $(if $(ARCH_IMAGE_PINS),$(or $(shell cat '$(ARCH_IMAGE_PINS)/$(subst :,_,$(subst /,_,$(1)))' 2>/dev/null),$(error No digest of $(1) was pushed by this workflow run)),$(1)) + buildx-imagetools-create: docker buildx imagetools create -t $(REPO):$(IMAGETOOLS_TAG) \ - $(REPO):$(TAG)-amd64 \ - $(REPO):$(TAG)-arm64 + $(call arch-image,$(REPO):$(TAG)-amd64) \ + $(call arch-image,$(REPO):$(TAG)-arm64) .PHONY: buildx-imagetools-create test: diff --git a/base-images.mk b/base-images.mk index c6610ee..2d30087 100644 --- a/base-images.mk +++ b/base-images.mk @@ -3,11 +3,11 @@ BASE_IMAGE_REPOSITORY := python BASE_IMAGE_VERSION_SUFFIX := -alpine -BASE_IMAGE_DIGEST_3.11.17-alpine := sha256:03c8e956bf1eee7763faf3a9fbb24b3ff9c0496cc2dbc5bcb0d6ac1f6268a287 -BASE_IMAGE_DIGEST_3.12.15-alpine := sha256:92abd2ba1bdfb48b1e2ac224b582dd1558d0d4bb11c903b126b5bf9c448fd656 -BASE_IMAGE_DIGEST_3.13.17-alpine := sha256:8f72324dfc4b4c94f1599faf1c037c8e74755d5dbbea63f1f51a89fa52f3ad07 -BASE_IMAGE_DIGEST_3.14.9-alpine := sha256:d55673c233e28839c1c0c69766428cb6d50174a2ecfdcf915b6f58a0b0991562 -BASE_IMAGE_DIGEST_3.15.1-alpine := sha256:e85751f6fe48ddb0619557d606ad93685134347a821b85fd9cd9dfa61addb970 +BASE_IMAGE_DIGEST_3.11.18-alpine := sha256:7fbad8e4652eae0186429a6f26cf5b23e27e8c6fd7ac4d0cfd7a6988cdeea1e1 +BASE_IMAGE_DIGEST_3.12.16-alpine := sha256:c5ba3deef00c7758561a0f03c26f44f10589263d40e732b8748e0d1f38f6dd89 +BASE_IMAGE_DIGEST_3.13.18-alpine := sha256:9ef1a599f863231c3d91e941389bfdc4a2d6070557243d54df1a4e57015b960e +BASE_IMAGE_DIGEST_3.14.10-alpine := sha256:5862d971d1f0ae26b258cefa4e893556b1d3aba81bd2ff30888704ad378bab67 +BASE_IMAGE_DIGEST_3.15.2-alpine := sha256:0f9552bb28711333da16915ec146f5e6bb44a7fdac9ced15dc17c2e0206346dd # Fail before building when a version or variant has no reviewed pin. BASE_IMAGE = $(BASE_IMAGE_REPOSITORY):$(BASE_IMAGE_TAG)@$(or $(BASE_IMAGE_DIGEST_$(BASE_IMAGE_TAG)),$(error No base image digest for $(BASE_IMAGE_REPOSITORY):$(BASE_IMAGE_TAG); update base-images.mk))