Skip to content

Commit 1b4c8b6

Browse files
committed
chore(kilo): rebuild kilo image on current upstream and alpine 3.24
Rebuilds the first-party kilo image to clear the published libpng advisories carried by the stale pinned layers and to pick up current upstream: - ARG VERSION: squat/kilo main fbce60d8 -> 944dff57 (the rebuild also refreshes the golang:1.25 stdlib compiled into the kg / kgctl binaries) - runtime and cni base: alpine 3.23 -> 3.24, which clears the libpng16-16 / libpng advisories pulled in through the graphviz / font-noto chain - CNI plugins: v1.9.0 -> v1.9.1 - values.yaml: re-pinned to the rebuilt multi-arch digest; the tag handle moves from latest to v<version> to match the sibling first-party images The in-repo cross-mesh-granularity feature patch still applies cleanly on the new HEAD and is verified in the built binary (kg --mesh-granularity lists `cross`). Adds the package's first helm-unittest coverage, pinning the image ref and the default mesh-arg wiring. Assisted-By: Claude <[email protected]> Signed-off-by: Aleksei Sviridkin <[email protected]>
1 parent 0e2e6e1 commit 1b4c8b6

4 files changed

Lines changed: 74 additions & 5 deletions

File tree

‎packages/system/kilo/Makefile‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@ export NAMESPACE=cozy-$(NAME)
44
include ../../../hack/common-envs.mk
55
include ../../../hack/package.mk
66

7+
test:
8+
helm unittest .
9+
710
update:
811
sha=$$(git ls-remote https://github.com/squat/kilo refs/heads/main | awk '{print $$1}') && \
912
sed -i "/ARG VERSION/ s|=.*|=$${sha}|g" images/kilo/Dockerfile

‎packages/system/kilo/images/kilo/Dockerfile‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Build the kg binary
22
FROM --platform=$BUILDPLATFORM golang:1.25 AS builder
33

4-
ARG VERSION=fbce60d8033da073748f5b0d6ce0f1e216f03e7f
4+
ARG VERSION=944dff5745d747c06555a964c2137b9a986ff6ec
55
ARG TARGETOS
66
ARG TARGETARCH
77

@@ -23,14 +23,14 @@ RUN GOOS=$TARGETOS GOARCH=$TARGETARCH CGO_ENABLED=0 go build \
2323
-a -o kgctl ./cmd/kgctl
2424

2525
# Download CNI plugins
26-
FROM alpine:3.23 AS cni
26+
FROM alpine:3.24 AS cni
2727
ARG TARGETARCH
28-
ARG CNI_PLUGINS_VERSION=v1.9.0
28+
ARG CNI_PLUGINS_VERSION=v1.9.1
2929
RUN apk add --no-cache curl && \
3030
curl -Lo cni.tar.gz https://github.com/containernetworking/plugins/releases/download/$CNI_PLUGINS_VERSION/cni-plugins-linux-$TARGETARCH-$CNI_PLUGINS_VERSION.tgz && \
3131
tar -xf cni.tar.gz
3232

33-
FROM alpine:3.23
33+
FROM alpine:3.24
3434
RUN apk add --no-cache ipset iptables ip6tables graphviz font-noto
3535
COPY --from=cni bridge host-local loopback portmap /opt/cni/bin/
3636
ADD https://raw.githubusercontent.com/kubernetes-sigs/iptables-wrappers/e139a115350974aac8a82ec4b815d2845f86997e/iptables-wrapper-installer.sh /
Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
suite: kilo DaemonSet image pin and mesh-arg wiring
2+
3+
# Pins the surface this package owns on top of the vendored squat/kilo binary:
4+
# - the kilo DaemonSet pulls the first-party image from the cozystack
5+
# registry (repository is the load-bearing ref re-pinned by `make image`);
6+
# - the default mesh args (location granularity, transit subnet, auto MTU,
7+
# cni disabled, crosssubnet encapsulation) render as the kg binary expects;
8+
# - meshGranularity plumbs through verbatim, including the `cross` value that
9+
# the in-repo feat-add-cross-mesh-granularity.diff teaches the image to
10+
# accept (the chart passes it straight to --mesh-granularity);
11+
# - the cilium compatibility overlay adds --compatibility=cilium, and the
12+
# default render carries no --compatibility arg.
13+
14+
templates:
15+
- templates/kilo.yaml
16+
17+
tests:
18+
- it: "DaemonSet pulls the first-party kilo image from the cozystack registry"
19+
asserts:
20+
- isKind:
21+
of: DaemonSet
22+
- matchRegex:
23+
path: spec.template.spec.containers[0].image
24+
pattern: "^ghcr\\.io/cozystack/cozystack/kilo:"
25+
26+
- it: "default mesh args render as the kg binary expects"
27+
asserts:
28+
- contains:
29+
path: spec.template.spec.containers[0].args
30+
content: "--cni=false"
31+
- contains:
32+
path: spec.template.spec.containers[0].args
33+
content: "--encapsulate=crosssubnet"
34+
- contains:
35+
path: spec.template.spec.containers[0].args
36+
content: "--mesh-granularity=location"
37+
- contains:
38+
path: spec.template.spec.containers[0].args
39+
content: "--subnet=100.66.0.0/16"
40+
- contains:
41+
path: spec.template.spec.containers[0].args
42+
content: "--mtu=auto"
43+
44+
- it: "meshGranularity=cross plumbs through to the patched binary"
45+
set:
46+
kilo:
47+
meshGranularity: cross
48+
asserts:
49+
- contains:
50+
path: spec.template.spec.containers[0].args
51+
content: "--mesh-granularity=cross"
52+
53+
- it: "cilium compatibility overlay adds --compatibility=cilium"
54+
set:
55+
kilo:
56+
compatibility: cilium
57+
asserts:
58+
- contains:
59+
path: spec.template.spec.containers[0].args
60+
content: "--compatibility=cilium"
61+
62+
- it: "no --compatibility arg in the default render"
63+
asserts:
64+
- notContains:
65+
path: spec.template.spec.containers[0].args
66+
content: "--compatibility=cilium"

‎packages/system/kilo/values.yaml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
kilo:
22
image:
33
pullPolicy: IfNotPresent
4-
tag: latest@sha256:016d054fcbb31d77ecfc8a0e7ead9f8cc01fb2f5a12b619d4fb0b7d745414df0
4+
tag: v1.5.0@sha256:fe837f428504f6c6e9e4582326a3bf9cd507a9cca58c975952f5cc0b34728f63
55
repository: ghcr.io/cozystack/cozystack/kilo
66
transitCIDR: 100.66.0.0/16
77
meshGranularity: location

0 commit comments

Comments
 (0)