base: yq follows latest (was pinned v4.53.3), gate on major v4

Match the repo's latest-following convention (tealdeer/uv/etc.) and keep the
container in sync with the Mac's brew yq. smoke-test now asserts mikefarah AND
major v4, so a surprise yq v5 fails CI instead of silently breaking
provision.sh. Pin still available via --build-arg YQ_VERSION=vX.Y.Z.
This commit is contained in:
pi
2026-06-25 16:33:27 +02:00
parent 9ab9a28458
commit cda488c565
3 changed files with 11 additions and 10 deletions
+5 -6
View File
@@ -19,12 +19,11 @@ Pre-v1.0.0 tags followed the pi npm version (`v{pi_version}[letter]`).
previously apt-installed `yq`, which on Debian/Ubuntu is the unrelated previously apt-installed `yq`, which on Debian/Ubuntu is the unrelated
kislyuk/`yq` (a jq wrapper, v3.x) — incompatible with the mikefarah v4 syntax kislyuk/`yq` (a jq wrapper, v3.x) — incompatible with the mikefarah v4 syntax
the `cloud-init` repo's `provision.sh`/`deploy.sh` expect. Dropped the apt the `cloud-init` repo's `provision.sh`/`deploy.sh` expect. Dropped the apt
package and install a pinned mikefarah binary instead package and install the mikefarah binary instead (multi-arch amd64/arm64,
(`ARG YQ_VERSION=v4.53.3`, multi-arch amd64/arm64, follows the repo's following the repo's `latest` convention like `tealdeer`/`uv`; pin a tag
tealdeer-style `latest`-or-pin pattern; override with `--build-arg`), with `--build-arg YQ_VERSION=vX.Y.Z`). The build-time `smoke-test.sh` gate
matching the `yq` used on control machines (Homebrew `yq` v4.x). The asserts `yq --version` reports `mikefarah` **and** major **v4**, so both a
build-time `smoke-test.sh` gate now asserts `yq --version` reports regression to the Python package and a surprise future yq v5 fail CI.
`mikefarah`, so a regression back to the Python package fails CI.
--- ---
+5 -3
View File
@@ -408,9 +408,11 @@ RUN ARCH=$(case "${TARGETARCH}" in amd64) echo "x86_64" ;; arm64) echo "aarch64"
# Installed as the mikefarah Go binary — NOT Debian's `yq` apt package, which # Installed as the mikefarah Go binary — NOT Debian's `yq` apt package, which
# is the unrelated Python kislyuk/yq (a jq wrapper with different syntax and # is the unrelated Python kislyuk/yq (a jq wrapper with different syntax and
# version line, e.g. 3.x). The cloud-init repo's deploy.sh/provision.sh # version line, e.g. 3.x). The cloud-init repo's deploy.sh/provision.sh
# require mikefarah yq v4; pinned here to the v4.x release used on the # require mikefarah yq v4 (the unrelated Debian python yq is v3.x). Follows
# control machines (override with --build-arg YQ_VERSION=latest|vX.Y.Z). # the repo's `latest` convention (like tealdeer/uv/etc.); the smoke test pins
ARG YQ_VERSION=v4.53.3 # the contract to major v4, so a future yq v5 fails CI instead of silently
# breaking provision.sh. Pin a specific tag with --build-arg YQ_VERSION=vX.Y.Z.
ARG YQ_VERSION=latest
RUN ARCH=$(case "${TARGETARCH}" in amd64) echo "amd64" ;; arm64) echo "arm64" ;; *) echo "amd64" ;; esac) && \ RUN ARCH=$(case "${TARGETARCH}" in amd64) echo "amd64" ;; arm64) echo "arm64" ;; *) echo "amd64" ;; esac) && \
V="${YQ_VERSION}" && \ V="${YQ_VERSION}" && \
if [ "$V" = "latest" ]; then \ if [ "$V" = "latest" ]; then \
+1 -1
View File
@@ -76,7 +76,7 @@ run "mempalace-mcp" "mempalace-mcp --help"
run "pandoc" "pandoc --version" run "pandoc" "pandoc --version"
run "graphviz (dot)" "dot -V" run "graphviz (dot)" "dot -V"
run "imagemagick" "magick --version" run "imagemagick" "magick --version"
run "yq (mikefarah v4)" "yq --version | grep -q mikefarah" run "yq (mikefarah v4)" "yq --version | grep -qE 'mikefarah.*version v4'"
run "tldr (tealdeer)" "tldr --version" run "tldr (tealdeer)" "tldr --version"
run "socat" "socat -V" run "socat" "socat -V"
run "studio-expose helper" "test -x /usr/local/bin/studio-expose" run "studio-expose helper" "test -x /usr/local/bin/studio-expose"