Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

setcap: switch to debian bookworm #3139

Merged
merged 1 commit into from
Jul 11, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 21 additions & 22 deletions dependencies.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -431,10 +431,11 @@ dependencies:
match: OS_CODENAME\ \?=\ bullseye
- path: images/build/go-runner/variants.yaml
match: "OS_CODENAME: 'bullseye'"
- path: images/build/setcap/Makefile
match: CONFIG\ \?=\ bullseye
- path: images/build/setcap/variants.yaml
match: "CONFIG: 'bullseye'"
# TODO: revert once all images are on bookworm
# - path: images/build/setcap/Makefile
# match: CONFIG\ \?=\ bullseye
# - path: images/build/setcap/variants.yaml
# match: "CONFIG: 'bullseye'"
- path: images/releng/ci/variants.yaml
match: "OS_CODENAME: 'bullseye'"
- path: images/releng/k8s-ci-builder/Makefile
Expand Down Expand Up @@ -468,17 +469,16 @@ dependencies:
match: "IMAGE_VERSION: 'bookworm-v((([0-9]+)\\.([0-9]+)\\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)'"

- name: "registry.k8s.io/build-image/debian-base: dependents"
version: bullseye-v1.4.3
version: bookworm-v1.0.0
refPaths:
# TODO: revert once all images are on bookworm
# - path: images/build/debian-iptables/Makefile
# match: DEBIAN_BASE_VERSION\ \?=\ bullseye-v((([0-9]+)\.([0-9]+)\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?)(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?)
# - path: images/build/debian-iptables/variants.yaml
# match: "DEBIAN_BASE_VERSION: 'bullseye-v((([0-9]+)\\.([0-9]+)\\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)'"
- path: images/build/debian-iptables/Makefile
match: DEBIAN_BASE_VERSION\ \?=\ bookworm-v((([0-9]+)\.([0-9]+)\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?)(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?)
- path: images/build/debian-iptables/variants.yaml
match: "DEBIAN_BASE_VERSION: 'bookworm-v((([0-9]+)\\.([0-9]+)\\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)'"
- path: images/build/setcap/Makefile
match: DEBIAN_BASE_VERSION\ \?=\ bullseye-v((([0-9]+)\.([0-9]+)\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?)(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?)
match: DEBIAN_BASE_VERSION\ \?=\ bookworm-v((([0-9]+)\.([0-9]+)\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?)(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?)
- path: images/build/setcap/variants.yaml
match: "DEBIAN_BASE_VERSION: 'bullseye-v((([0-9]+)\\.([0-9]+)\\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)'"
match: "DEBIAN_BASE_VERSION: 'bookworm-v((([0-9]+)\\.([0-9]+)\\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)'"

- name: "registry.k8s.io/build-image/debian-iptables"
version: bookworm-v1.0.0
Expand All @@ -503,12 +503,12 @@ dependencies:
match: GORUNNER_VERSION \?= v\d+\.\d+\.\d+-go\d+.\d+(alpha|beta|rc)?\.?(\d+)?-bullseye\.\d+

- name: "registry.k8s.io/build-image/setcap"
version: bullseye-v1.4.2
version: bookworm-v1.0.0
refPaths:
- path: images/build/setcap/Makefile
match: IMAGE_VERSION\ \?=\ bullseye-v((([0-9]+)\.([0-9]+)\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?)(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?)
match: IMAGE_VERSION\ \?=\ bookworm-v((([0-9]+)\.([0-9]+)\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?)(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?)
- path: images/build/setcap/variants.yaml
match: "IMAGE_VERSION: 'bullseye-v((([0-9]+)\\.([0-9]+)\\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)'"
match: "IMAGE_VERSION: 'bookworm-v((([0-9]+)\\.([0-9]+)\\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)'"

# Base images (next candidate)
- name: "registry.k8s.io/build-image/debian-base (next candidate)"
Expand All @@ -518,13 +518,12 @@ dependencies:
match: "IMAGE_VERSION: 'bookworm-v((([0-9]+)\\.([0-9]+)\\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)'"

- name: "registry.k8s.io/build-image/debian-base: dependents (next candidate)"
version: bullseye-v1.4.3
version: bookworm-v1.0.0
refPaths:
# TODO: revert once all images are on bookworm
# - path: images/build/debian-iptables/variants.yaml
# match: "DEBIAN_BASE_VERSION: 'bullseye-v((([0-9]+)\\.([0-9]+)\\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)'"
- path: images/build/debian-iptables/variants.yaml
match: "DEBIAN_BASE_VERSION: 'bookworm-v((([0-9]+)\\.([0-9]+)\\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)'"
- path: images/build/setcap/variants.yaml
match: "DEBIAN_BASE_VERSION: 'bullseye-v((([0-9]+)\\.([0-9]+)\\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)'"
match: "DEBIAN_BASE_VERSION: 'bookworm-v((([0-9]+)\\.([0-9]+)\\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)'"

- name: "registry.k8s.io/build-image/debian-iptables (next candidate)"
version: bookworm-v1.0.0
Expand All @@ -533,10 +532,10 @@ dependencies:
match: "IMAGE_VERSION: 'bookworm-v((([0-9]+)\\.([0-9]+)\\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)'"

- name: "registry.k8s.io/build-image/setcap (next candidate)"
version: bullseye-v1.4.2
version: bookworm-v1.0.0
refPaths:
- path: images/build/setcap/variants.yaml
match: "IMAGE_VERSION: 'bullseye-v((([0-9]+)\\.([0-9]+)\\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)'"
match: "IMAGE_VERSION: 'bookworm-v((([0-9]+)\\.([0-9]+)\\.([0-9]+)(?:-([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?)'"

# Build environments
- name: "gcr.io/k8s-staging-test-infra/gcb-docker-gcloud"
Expand Down
6 changes: 2 additions & 4 deletions images/build/setcap/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,5 @@ FROM ${BASEIMAGE}

ARG BASEIMAGE

RUN apt-get update \
&& CODENAME=$(. /etc/os-release; echo $VERSION_CODENAME) && \
if [ "bullseye" = "$CODENAME" ]; then apt-get -y --allow-change-held-packages install libcap2; fi \
&& apt-get -y --no-install-recommends install libcap2-bin
RUN apt-get update && \
apt-get -y --allow-change-held-packages install libcap2 libcap2-bin
6 changes: 3 additions & 3 deletions images/build/setcap/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ REGISTRY?="gcr.io/k8s-staging-build-image"
IMAGE=$(REGISTRY)/setcap

TAG ?= $(shell git describe --tags --always --dirty)
IMAGE_VERSION ?= bullseye-v1.4.2
CONFIG ?= bullseye
DEBIAN_BASE_VERSION ?= bullseye-v1.4.3
IMAGE_VERSION ?= bookworm-v1.0.0
CONFIG ?= bookworm
DEBIAN_BASE_VERSION ?= bookworm-v1.0.0

ARCH?=amd64
ALL_ARCH = amd64 arm arm64 ppc64le s390x
Expand Down
5 changes: 5 additions & 0 deletions images/build/setcap/variants.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,8 @@ variants:
CONFIG: 'bullseye'
IMAGE_VERSION: 'bullseye-v1.4.2'
DEBIAN_BASE_VERSION: 'bullseye-v1.4.3'
# Debian 12 - Kubernetes 1.28 and newer
bookworm:
CONFIG: 'bookworm'
IMAGE_VERSION: 'bookworm-v1.0.0'
DEBIAN_BASE_VERSION: 'bookworm-v1.0.0'