From 75ad649e08bd70d13b496f1d2da3cb19c3de35df Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Gronowski?= Date: Tue, 30 Jun 2026 17:24:03 +0200 Subject: [PATCH 1/2] static: Flatten archive structure MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Previously the tgz/zip archives contained a named subdirectory (e.g. containerd.io/, docker-buildx/, docker-compose/), requiring users to cd into it after extraction. Change the tar and zip commands to archive from inside the staging directory so all files (binaries, LICENSE, README.md) land directly at the archive root. Signed-off-by: Paweł Gronowski --- pkg/agent/scripts/pkg-static-build.sh | 6 +++--- pkg/buildx/scripts/pkg-static-build.sh | 6 +++--- pkg/compose/scripts/pkg-static-build.sh | 6 +++--- pkg/containerd/scripts/pkg-static-build.sh | 6 +++--- pkg/credential-helpers/scripts/pkg-static-build.sh | 6 +++--- pkg/docker-cli/scripts/pkg-static-build.sh | 6 +++--- pkg/docker-engine/scripts/pkg-static-build.sh | 6 +++--- pkg/model/scripts/pkg-static-build.sh | 6 +++--- 8 files changed, 24 insertions(+), 24 deletions(-) diff --git a/pkg/agent/scripts/pkg-static-build.sh b/pkg/agent/scripts/pkg-static-build.sh index 61e63bc0..15f830ed 100755 --- a/pkg/agent/scripts/pkg-static-build.sh +++ b/pkg/agent/scripts/pkg-static-build.sh @@ -78,13 +78,13 @@ for pkgname in *; do if [ "$(xx-info os)" = "windows" ]; then ( set -x - cd "$workdir" - zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" "${pkgname}" + cd "$workdir/${pkgname}" + zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" . ) else ( set -x - tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir" "${pkgname}" + tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . ) fi done diff --git a/pkg/buildx/scripts/pkg-static-build.sh b/pkg/buildx/scripts/pkg-static-build.sh index 2f4268c1..36d92943 100755 --- a/pkg/buildx/scripts/pkg-static-build.sh +++ b/pkg/buildx/scripts/pkg-static-build.sh @@ -75,13 +75,13 @@ for pkgname in *; do if [ "$(xx-info os)" = "windows" ]; then ( set -x - cd "$workdir" - zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" "${pkgname}" + cd "$workdir/${pkgname}" + zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" . ) else ( set -x - tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir" "${pkgname}" + tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . ) fi done diff --git a/pkg/compose/scripts/pkg-static-build.sh b/pkg/compose/scripts/pkg-static-build.sh index a59ee7bb..9d8e8313 100755 --- a/pkg/compose/scripts/pkg-static-build.sh +++ b/pkg/compose/scripts/pkg-static-build.sh @@ -80,13 +80,13 @@ for pkgname in *; do if [ "$(xx-info os)" = "windows" ]; then ( set -x - cd "$workdir" - zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" "${pkgname}" + cd "$workdir/${pkgname}" + zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" . ) else ( set -x - tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir" "${pkgname}" + tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . ) fi done diff --git a/pkg/containerd/scripts/pkg-static-build.sh b/pkg/containerd/scripts/pkg-static-build.sh index 3ed0591a..0520ecc2 100755 --- a/pkg/containerd/scripts/pkg-static-build.sh +++ b/pkg/containerd/scripts/pkg-static-build.sh @@ -134,13 +134,13 @@ for pkgname in *; do if [ "$(xx-info os)" = "windows" ]; then ( set -x - cd "$workdir" - zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" "${pkgname}" + cd "$workdir/${pkgname}" + zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" . ) else ( set -x - tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir" "${pkgname}" + tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . ) fi done diff --git a/pkg/credential-helpers/scripts/pkg-static-build.sh b/pkg/credential-helpers/scripts/pkg-static-build.sh index 2525a157..12dbab72 100755 --- a/pkg/credential-helpers/scripts/pkg-static-build.sh +++ b/pkg/credential-helpers/scripts/pkg-static-build.sh @@ -102,13 +102,13 @@ for pkgname in *; do if [ "$(xx-info os)" = "windows" ]; then ( set -x - cd "$workdir" - zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" "${pkgname}" + cd "$workdir/${pkgname}" + zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" . ) else ( set -x - tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir" "${pkgname}" + tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . ) fi done diff --git a/pkg/docker-cli/scripts/pkg-static-build.sh b/pkg/docker-cli/scripts/pkg-static-build.sh index 3beb0250..016ea44b 100755 --- a/pkg/docker-cli/scripts/pkg-static-build.sh +++ b/pkg/docker-cli/scripts/pkg-static-build.sh @@ -82,13 +82,13 @@ for pkgname in *; do if [ "$(xx-info os)" = "windows" ]; then ( set -x - cd "$workdir" - zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" "${pkgname}" + cd "$workdir/${pkgname}" + zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" . ) else ( set -x - tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir" "${pkgname}" + tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . ) fi done diff --git a/pkg/docker-engine/scripts/pkg-static-build.sh b/pkg/docker-engine/scripts/pkg-static-build.sh index 219da10d..29505894 100755 --- a/pkg/docker-engine/scripts/pkg-static-build.sh +++ b/pkg/docker-engine/scripts/pkg-static-build.sh @@ -100,13 +100,13 @@ for pkgname in *; do if [ "$(xx-info os)" = "windows" ]; then ( set -x - cd "$workdir" - zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" "${pkgname}" + cd "$workdir/${pkgname}" + zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" . ) else ( set -x - tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir" "${pkgname}" + tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . ) fi done diff --git a/pkg/model/scripts/pkg-static-build.sh b/pkg/model/scripts/pkg-static-build.sh index d0d990ec..740db53a 100755 --- a/pkg/model/scripts/pkg-static-build.sh +++ b/pkg/model/scripts/pkg-static-build.sh @@ -76,13 +76,13 @@ for pkgname in *; do if [ "$(xx-info os)" = "windows" ]; then ( set -x - cd "$workdir" - zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" "${pkgname}" + cd "$workdir/${pkgname}" + zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" . ) else ( set -x - tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir" "${pkgname}" + tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . ) fi done From 5402fb1a239d94cef0ab6070d4fc74fee1d8a3e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Gronowski?= Date: Tue, 30 Jun 2026 17:52:38 +0200 Subject: [PATCH 2/2] static: Use hyphen as version separator in archive names MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change archive filenames from `pkgname_version` to `pkgname-version` (e.g. containerd-1.2.3.tgz instead of containerd_1.2.3.tgz) across all pkg-static-build.sh scripts. This matches current download.docker.com naming Signed-off-by: Paweł Gronowski --- pkg/agent/scripts/pkg-static-build.sh | 4 ++-- pkg/buildx/scripts/pkg-static-build.sh | 4 ++-- pkg/compose/scripts/pkg-static-build.sh | 4 ++-- pkg/containerd/scripts/pkg-static-build.sh | 4 ++-- pkg/credential-helpers/scripts/pkg-static-build.sh | 4 ++-- pkg/docker-cli/scripts/pkg-static-build.sh | 4 ++-- pkg/docker-engine/scripts/pkg-static-build.sh | 4 ++-- pkg/model/scripts/pkg-static-build.sh | 4 ++-- 8 files changed, 16 insertions(+), 16 deletions(-) diff --git a/pkg/agent/scripts/pkg-static-build.sh b/pkg/agent/scripts/pkg-static-build.sh index 15f830ed..166fa734 100755 --- a/pkg/agent/scripts/pkg-static-build.sh +++ b/pkg/agent/scripts/pkg-static-build.sh @@ -79,12 +79,12 @@ for pkgname in *; do ( set -x cd "$workdir/${pkgname}" - zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" . + zip -r "${pkgoutput}/${pkgname}-${GENVER_VERSION#v}.zip" . ) else ( set -x - tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . + tar -czf "${pkgoutput}/${pkgname}-${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . ) fi done diff --git a/pkg/buildx/scripts/pkg-static-build.sh b/pkg/buildx/scripts/pkg-static-build.sh index 36d92943..153bc3bd 100755 --- a/pkg/buildx/scripts/pkg-static-build.sh +++ b/pkg/buildx/scripts/pkg-static-build.sh @@ -76,12 +76,12 @@ for pkgname in *; do ( set -x cd "$workdir/${pkgname}" - zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" . + zip -r "${pkgoutput}/${pkgname}-${GENVER_VERSION#v}.zip" . ) else ( set -x - tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . + tar -czf "${pkgoutput}/${pkgname}-${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . ) fi done diff --git a/pkg/compose/scripts/pkg-static-build.sh b/pkg/compose/scripts/pkg-static-build.sh index 9d8e8313..c9b7865e 100755 --- a/pkg/compose/scripts/pkg-static-build.sh +++ b/pkg/compose/scripts/pkg-static-build.sh @@ -81,12 +81,12 @@ for pkgname in *; do ( set -x cd "$workdir/${pkgname}" - zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" . + zip -r "${pkgoutput}/${pkgname}-${GENVER_VERSION#v}.zip" . ) else ( set -x - tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . + tar -czf "${pkgoutput}/${pkgname}-${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . ) fi done diff --git a/pkg/containerd/scripts/pkg-static-build.sh b/pkg/containerd/scripts/pkg-static-build.sh index 0520ecc2..0111e1c5 100755 --- a/pkg/containerd/scripts/pkg-static-build.sh +++ b/pkg/containerd/scripts/pkg-static-build.sh @@ -135,12 +135,12 @@ for pkgname in *; do ( set -x cd "$workdir/${pkgname}" - zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" . + zip -r "${pkgoutput}/${pkgname}-${GENVER_VERSION#v}.zip" . ) else ( set -x - tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . + tar -czf "${pkgoutput}/${pkgname}-${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . ) fi done diff --git a/pkg/credential-helpers/scripts/pkg-static-build.sh b/pkg/credential-helpers/scripts/pkg-static-build.sh index 12dbab72..2cec50fa 100755 --- a/pkg/credential-helpers/scripts/pkg-static-build.sh +++ b/pkg/credential-helpers/scripts/pkg-static-build.sh @@ -103,12 +103,12 @@ for pkgname in *; do ( set -x cd "$workdir/${pkgname}" - zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" . + zip -r "${pkgoutput}/${pkgname}-${GENVER_VERSION#v}.zip" . ) else ( set -x - tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . + tar -czf "${pkgoutput}/${pkgname}-${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . ) fi done diff --git a/pkg/docker-cli/scripts/pkg-static-build.sh b/pkg/docker-cli/scripts/pkg-static-build.sh index 016ea44b..ad404c1e 100755 --- a/pkg/docker-cli/scripts/pkg-static-build.sh +++ b/pkg/docker-cli/scripts/pkg-static-build.sh @@ -83,12 +83,12 @@ for pkgname in *; do ( set -x cd "$workdir/${pkgname}" - zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" . + zip -r "${pkgoutput}/${pkgname}-${GENVER_VERSION#v}.zip" . ) else ( set -x - tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . + tar -czf "${pkgoutput}/${pkgname}-${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . ) fi done diff --git a/pkg/docker-engine/scripts/pkg-static-build.sh b/pkg/docker-engine/scripts/pkg-static-build.sh index 29505894..97d1a77d 100755 --- a/pkg/docker-engine/scripts/pkg-static-build.sh +++ b/pkg/docker-engine/scripts/pkg-static-build.sh @@ -101,12 +101,12 @@ for pkgname in *; do ( set -x cd "$workdir/${pkgname}" - zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" . + zip -r "${pkgoutput}/${pkgname}-${GENVER_VERSION#v}.zip" . ) else ( set -x - tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . + tar -czf "${pkgoutput}/${pkgname}-${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . ) fi done diff --git a/pkg/model/scripts/pkg-static-build.sh b/pkg/model/scripts/pkg-static-build.sh index 740db53a..74059e9c 100755 --- a/pkg/model/scripts/pkg-static-build.sh +++ b/pkg/model/scripts/pkg-static-build.sh @@ -77,12 +77,12 @@ for pkgname in *; do ( set -x cd "$workdir/${pkgname}" - zip -r "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.zip" . + zip -r "${pkgoutput}/${pkgname}-${GENVER_VERSION#v}.zip" . ) else ( set -x - tar -czf "${pkgoutput}/${pkgname}_${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . + tar -czf "${pkgoutput}/${pkgname}-${GENVER_VERSION#v}.tgz" -C "$workdir/${pkgname}" . ) fi done