Commit Graph

880 Commits

Author SHA1 Message Date
Sebastiaan van Stijn
39d4dbea9c Dockerfile: update debian frozen image to trixie-slim
docker buildx imagetools inspect docker.io/library/debian:trixie-slim
    Name:      docker.io/library/debian:trixie-slim
    MediaType: application/vnd.oci.image.index.v1+json
    Digest:    sha256:c85a2732e97694ea77237c61304b3bb410e0e961dd6ee945997a06c788c545bb

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-08-21 23:35:26 +02:00
Sebastiaan van Stijn
be7a769b69 Dockerfile: disable CGO for building utilities
Debian trixie is slimmed down, causing failures, but we probably don't
need CGO at all for these, so just disable it;

    > [swagger 2/2] RUN --mount=type=cache,target=/root/.cache/go-build,id=swagger-build-linux/arm64     --mount=type=cache,target=/go/pkg/mod     --mount=type=tmpfs,target=/go/src/ <<EOT (set -e...):
    12.22 go: downloading github.com/magiconair/properties v1.8.7
    12.29 go: downloading github.com/pelletier/go-toml/v2 v2.1.1
    12.44 go: downloading github.com/mitchellh/reflectwalk v1.0.2
    13.76 go: downloading golang.org/x/mod v0.17.0
    95.08 # github.com/go-swagger/go-swagger/cmd/swagger
    95.08 /usr/local/go/pkg/tool/linux_arm64/link: running aarch64-linux-gnu-gcc failed: exit status 1
    95.08 /usr/bin/aarch64-linux-gnu-gcc -Wl,-z,now -Wl,-z,nocopyreloc -fuse-ld=gold -Wl,--build-id=0xfd69e82d4bb4563abaec0df02ad550f5a6254e10 -o $WORK/b001/exe/a.out -rdynamic /tmp/go-link-2728250351/go.o /tmp/go-link-2728250351/000000.o /tmp/go-link-2728250351/000001.o /tmp/go-link-2728250351/000002.o /tmp/go-link-2728250351/000003.o /tmp/go-link-2728250351/000004.o /tmp/go-link-2728250351/000005.o /tmp/go-link-2728250351/000006.o /tmp/go-link-2728250351/000007.o /tmp/go-link-2728250351/000008.o /tmp/go-link-2728250351/000009.o /tmp/go-link-2728250351/000010.o /tmp/go-link-2728250351/000011.o /tmp/go-link-2728250351/000012.o /tmp/go-link-2728250351/000013.o /tmp/go-link-2728250351/000014.o /tmp/go-link-2728250351/000015.o /tmp/go-link-2728250351/000016.o /tmp/go-link-2728250351/000017.o /tmp/go-link-2728250351/000018.o /tmp/go-link-2728250351/000019.o /tmp/go-link-2728250351/000020.o /tmp/go-link-2728250351/000021.o -O2 -g -lresolv -O2 -g -ldl -O2 -g -lpthread
    95.08 collect2: fatal error: cannot find 'ld'
    95.08 compilation terminated.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-08-14 15:42:17 +02:00
Sebastiaan van Stijn
8de606beb1 Dockerfile: remove trailing slashes for GOBIN
It should be specified without (but works when included).

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-08-14 15:39:33 +02:00
Sebastiaan van Stijn
e1be10f5ed Merge pull request #50647 from thaJeztah/rm_vendor.mod
remove references to "vendor.mod"
2025-08-08 03:12:14 +02:00
Sebastiaan van Stijn
df3aea43aa remove references to "vendor.mod"
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-08-08 00:24:37 +02:00
Austin Vazquez
b25b421f97 update to go1.24.6
Signed-off-by: Austin Vazquez <austin.vazquez@docker.com>
2025-08-07 17:14:22 -05:00
Sebastiaan van Stijn
8be1b2372a Dockerfile: update containerd binary to v1.7.28
- release notes: https://github.com/containerd/containerd/releases/tag/v1.7.28
- full diff: https://github.com/containerd/containerd/v1.7.27...v1.7.28

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-08-07 22:03:38 +02:00
Sebastiaan van Stijn
f5f984eec6 Dockerfile: update runc binary to v1.3.0
- release notes: https://github.com/opencontainers/runc/releases/tag/v1.3.0
- full diff: https://github.com/opencontainers/runc/compare/v1.2.6..v1.3.0

-----

This is the first release of the 1.3.z release branch of runc. It
contains a few minor fixes for issues found in 1.3.0-rc.2.

This is the first release of runc that will follow our new release and
support policy (see RELEASES.md for more details). This means that, as
of this release:

* As of this release, the runc 1.2.z release branch will now only
  receive security and "significant" bugfixes.
* Users are encouraged to plan migrating to runc 1.3.0 as soon as
  possible.
* Due to its particular situation, runc 1.1.z is officially no longer
  supported and will no longer receive any updates (not even for
  critical security issues). Users are urged (in the strongest possible
  terms) to upgrade to a supported version of runc.
* Barring any future changes to our release policy, users should expect
  a runc 1.4.0 release in late October 2025.

Fixed

* Removed pre-emptive "full access to cgroups" warning when calling
  `runc pause` or `runc unpause` as an unprivileged user without
  `--systemd-cgroups`. Now the warning is only emitted if an actual permission
  error was encountered.
* Several fixes to our CI, mainly related to AlmaLinux and CRIU.

Changed

* In runc 1.2, we changed our mount behaviour to correctly handle clearing
  flags. However, the error messages we returned did not provide as much
  information to users about what clearing flags were conflicting with locked
  mount flags. We now provide more diagnostic information if there is an error
  when in the fallback path to handle locked mount flags.
* Upgrade our CI to use golangci-lint v2.0.
* `runc version` information is now filled in using `//go:embed` rather than
  being set through `Makefile`. This allows `go install` or other non-`make`
  builds to contain the correct version information. Note that
  `make EXTRA_VERSION=...` still works.
* Remove `exclude` directives from our `go.mod` for broken `cilium/ebpf`
  versions. `v0.17.3` resolved the issue we had, and `exclude` directives are
  incompatible with `go install`.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-08-06 13:51:00 +02:00
Sebastiaan van Stijn
e7c784c270 Dockerfile: add GO_SWAGGER_VERSION build-arg
Allow overriding the go-swagger version to install.

With this patch:

    docker build -q --call=outline --target=swagger .

    TARGET: swagger

    BUILD ARG            VALUE                    DESCRIPTION
    GO_VERSION           1.24.5
    BASE_DEBIAN_DISTRO   bookworm
    GOLANG_IMAGE         golang:1.24.5-bookworm
    XX_VERSION           1.6.1
    GO_SWAGGER_VERSION   v0.32.3                  specifies the version of the go-swagger binary to install.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-08-02 01:40:20 +02:00
Cory Snider
2783f80ecf api/types: generate with latest go-swagger
Override some of the templates to suppress emitting unwanted validation
and marshal/unmarshal code.

Signed-off-by: Cory Snider <csnider@mirantis.com>
2025-08-01 13:30:23 -04:00
Derek McGowan
65867642d3 Remove go module workarounds
Signed-off-by: Derek McGowan <derek@mcg.dev>
2025-07-31 10:49:02 -07:00
Sebastiaan van Stijn
098ff1aed1 Merge pull request #50405 from thaJeztah/bump_dev_tools
Dockerfile: update CLI to v28.3.2, Buildx v0.25.0, compose v2.38.2
2025-07-17 06:58:13 +02:00
Sebastiaan van Stijn
fb2117987d Dockerfile: upgrade Delve to v1.25.0
Update to the latest version:

- https://github.com/go-delve/delve/releases/tag/v1.25.0
- https://github.com/go-delve/delve/blob/v1.25.0/CHANGELOG.md#1250-2025-04-16

Also update links to supported platforms.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-07-13 17:33:31 +02:00
Sebastiaan van Stijn
18438f3c13 Dockerfile: update compose to v2.38.2
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-07-13 17:25:15 +02:00
Sebastiaan van Stijn
8c3e10a011 Dockerfile: update buildx to v0.25.0
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-07-13 17:24:22 +02:00
Sebastiaan van Stijn
4dee288b51 Dockerfile: update cli to v28.3.2
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-07-13 17:23:36 +02:00
Paweł Gronowski
0a047e825c update to go1.24.5
- https://github.com/golang/go/issues?q=milestone%3AGo1.24.5+label%3ACherryPickApproved
- full diff: https://github.com/golang/go/compare/go1.24.4...go1.24.5

This minor releases include 1 security fixes following the security policy:

- cmd/go: unexpected command execution in untrusted VCS repositories

    Various uses of the Go toolchain in untrusted VCS repositories can result in
    unexpected code execution. When using the Go toolchain in directories fetched
    using various VCS tools (such as directly cloning Git or Mercurial repositories)
    can cause the toolchain to execute unexpected commands, if said directory
    contains multiple VCS configuration metadata (such as a '.hg' directory in a Git
    repository). This is due to how the Go toolchain attempts to resolve which VCS
    is being used in order to embed build information in binaries and determine
    module versions.

    The toolchain will now abort attempting to resolve which VCS is being used if it
    detects multiple VCS configuration metadata in a module directory or nested VCS
    configuration metadata (such as a '.git' directoy in a parent directory and a
    '.hg' directory in a child directory). This will not prevent the toolchain from
    building modules, but will result in binaries omitting VCS related build
    information.

    If this behavior is expected by the user, the old behavior can be re-enabled by
    setting GODEBUG=allowmultiplevcs=1. This should only be done in trusted
    repositories.

    Thanks to RyotaK (https://ryotak.net) of GMO Flatt Security Inc for reporting
    this issue.

    This is CVE-2025-4674 and https://go.dev/issue/74380.

View the release notes for more information:
https://go.dev/doc/devel/release#go1.24.5

Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2025-07-08 19:21:37 +02:00
Sebastiaan van Stijn
4754c15e2b Dockerfile: bump gotest.tools/gotestsum v1.12.3 (for go1.25)
full diff: https://github.com/gotestyourself/gotestsum/compare/v1.12.0...v1.12.3

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-07-02 23:13:03 +02:00
CrazyMax
e7289e7e02 hack: check windows resources are set in the binary
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2025-06-26 17:03:32 +02:00
Kevin Alvarez
0ea20c9f72 cmd: fix winresources and move them out cli package
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2025-06-26 15:56:23 +02:00
Paweł Gronowski
1603ad636e update to go1.24.4
- https://github.com/golang/go/issues?q=milestone%3AGo1.24.4+label%3ACherryPickApproved
- full diff: https://github.com/golang/go/compare/go1.24.3...go1.24.4

This release includes 3 security fixes following the security policy:

- net/http: sensitive headers not cleared on cross-origin redirect

    Proxy-Authorization and Proxy-Authenticate headers persisted on cross-origin redirects potentially leaking sensitive information.

    Thanks to Takeshi Kaneko (GMO Cybersecurity by Ierae, Inc.) for reporting this issue.

    This is CVE-2025-4673 and Go issue https://go.dev/issue/73816.

- os: inconsistent handling of O_CREATE|O_EXCL on Unix and Windows

    os.OpenFile(path, os.O_CREATE|O_EXCL) behaved differently on Unix and Windows systems when the target path was a dangling symlink. On Unix systems, OpenFile with O_CREATE and O_EXCL flags never follows symlinks. On Windows, when the target path was a symlink to a nonexistent location, OpenFile would create a file in that location.

    OpenFile now always returns an error when the O_CREATE and O_EXCL flags are both set and the target path is a symlink.

    Thanks to Junyoung Park and Dong-uk Kim of KAIST Hacking Lab for discovering this issue.

    This is CVE-2025-0913 and Go issue https://go.dev/issue/73702.

- crypto/x509: usage of ExtKeyUsageAny disables policy validation

    Calling Verify with a VerifyOptions.KeyUsages that contains ExtKeyUsageAny unintentionally disabledpolicy validation. This only affected certificate chains which contain policy graphs, which are rather uncommon.

    Thanks to Krzysztof Skrzętnicki (@Tener) of Teleport for reporting this issue.

    This is CVE-2025-22874 and Go issue https://go.dev/issue/73612.

Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2025-06-06 19:35:32 +02:00
Sebastiaan van Stijn
284904119a Dockerfile: update cli to v28.2.2
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-06-02 14:54:44 +02:00
Sebastiaan van Stijn
048199f191 Dockerfile: update cli to v28.2.0-rc.2
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-05-27 22:54:09 +02:00
Paweł Gronowski
67535a4454 Merge pull request #50084 from thaJeztah/q_ctr_c_let_me_out_of_here_wq_wq_wq
Dockerfile: install nano as alternative to vim
2025-05-27 11:11:17 +00:00
Sebastiaan van Stijn
339be4e2ae Dockerfile: install nano as alternative to vim
I'm horrible at vim, and use nano as my go-to editor for quick changes.
Let's install nano in the dev-container as alternative to vim for those
like me, who are not so vim-savvy ^O^C^C:wq:

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-05-27 10:29:19 +02:00
Sebastiaan van Stijn
cd2702e04e Dockerfile: update compose to v2.36.2
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-05-26 18:37:39 +02:00
Sebastiaan van Stijn
01fec904e4 Dockerfile: update buildx to v0.24.0
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-05-26 18:35:26 +02:00
Sebastiaan van Stijn
7130cd4f16 Remove DockerSchema1RegistrySuite schema 2 version 1 tests
Also remove the DOCKER_ALLOW_SCHEMA1_PUSH_DONOTUSE from Jenkins

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-05-16 18:00:06 +02:00
Akihiro Suda
49e43afb47 Merge pull request #49997 from thaJeztah/bump_crun
Dockerfile: update crun to 1.21
2025-05-16 00:57:02 +09:00
Sebastiaan van Stijn
ba2ddd75e4 Dockerfile: update crun to 1.21
full diff: https://github.com/containers/crun/compare/1.12...1.21

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-05-15 16:55:46 +02:00
Akihiro Suda
2c5f8c51c5 Merge pull request #49996 from thaJeztah/bump_compose
Dockerfile: update compose to v2.36.0
2025-05-15 23:46:25 +09:00
Sebastiaan van Stijn
7bc6fd09da Dockerfile: update compose to v2.36.0
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-05-15 14:05:20 +02:00
Matthieu MOREL
7b5d2b4ec3 chore: bump golangci-lint to v2
Signed-off-by: Matthieu MOREL <matthieu.morel35@gmail.com>
2025-05-15 10:00:16 +02:00
Sebastiaan van Stijn
e991c7185d update to go1.24.3
release notes: https://go.dev/doc/go1.24

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-05-12 10:31:00 +02:00
Paweł Gronowski
dfd59c0a95 Dockerfile: Fetch vpnkit from moby org
`moby/vpnkit` now officially pushes a binary image to `moby/vpnkit-bin`
repository on Docker Hub.
Use it to fetch the vpnkit binary.

Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2025-04-24 14:11:00 +02:00
Sebastiaan van Stijn
2808e59f4c Dockerfile: update compose to v2.35.1
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-04-18 18:00:48 +02:00
Sebastiaan van Stijn
a75be33ba0 Dockerfile: update buildx to v0.23.0
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-04-18 18:00:48 +02:00
Sebastiaan van Stijn
dd36139b1a Dockerfile: update cli to v28.1.1
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-04-18 18:00:42 +02:00
Sebastiaan van Stijn
f1e3ed0c48 Dockerfile: don't pin syntax to 1.7
The syntax was pinned for 1.7 in f696e0d2a7
possibly because it was not yet promoted as "latest stable" at the
time.

I don't think we need to pin to an old version, and just go with
the latest, so that we can use the latest features provided.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-04-18 18:00:13 +02:00
Paweł Gronowski
fb2983ab0d Merge pull request #49677 from vvoland/integration-cli-bump-cli
integration-cli: Update default CLI version to v18.06.3-ce
2025-04-11 10:32:36 +00:00
Sebastiaan van Stijn
f96dc9d1a5 Dockerfile: update registry to v3.0.0
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-04-10 15:54:11 +02:00
Paweł Gronowski
fab94808f5 integration-cli: Update default CLI version to v18.06.3-ce
This updates the Docker CLI version used for integration-cli tests from
v17.06.2-ce to v18.06.3-ce.

v18.06 is the first one that supports enabling BuildKit.

Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2025-04-10 11:39:13 +02:00
CrazyMax
f410dbda88 dockerfile: dind target to build docker image for testing
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2025-04-08 11:48:33 +02:00
Sebastiaan van Stijn
74b71c41ac update to go1.23.8 (fix CVE-2025-22871)
full diff: https://github.com/golang/go/compare/go1.23.7...go1.23.8
release notes: https://go.dev/doc/devel/release#go1.24.2

go1.23.8 (released 2025-04-01) includes security fixes to the net/http package,
as well as bug fixes to the runtime and the go command. See the Go 1.23.8
milestone on our issue tracker for details;

https://github.com/golang/go/issues?q=milestone%3AGo1.23.8+label%3ACherryPickApproved

From the mailing list:

Hello gophers,

We have just released Go versions 1.24.2 and 1.23.8, minor point releases.
These minor releases include 1 security fixes following the security policy:

- net/http: request smuggling through invalid chunked data
  The net/http package accepted data in the chunked transfer encoding
  containing an invalid chunk-size line terminated by a bare LF.
  When used in conjunction with a server or proxy which incorrectly
  interprets a bare LF in a chunk extension as part of the extension,
  this could permit request smuggling.
  The net/http package now rejects chunk-size lines containing a bare LF.
  Thanks to Jeppe Bonde Weikop for reporting this issue.
  This is CVE-2025-22871 and Go issue https://go.dev/issue/71988.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-04-03 12:30:00 +02:00
Rob Murray
dc963a00c1 Firewalld should use its nftables backend
Since commit cfc049c the dev container has been using iptables-nft,
but the Dockerfile configured firewalld to use its iptables backend
(if firewalld is enabled, which it accidentally hasn't been in CI).

The integration tests run ok for a while, then some things start
failing with the less than obvious message:

  Error: COMMAND_FAILED: UNKNOWN_ERROR: nonexistent or underflow of priority count

So, let firewalld use its default nftables backend.

Signed-off-by: Rob Murray <rob.murray@docker.com>
2025-03-27 08:36:09 +00:00
Sebastiaan van Stijn
6de8ba3bc5 Merge pull request #49688 from thaJeztah/disable_go_telemetry
Dockerfile: disable saving Golang telemetry in dev-container
2025-03-26 17:25:34 +01:00
Akihiro Suda
f6a642f588 Merge pull request #49689 from thaJeztah/dockerfile_update_registry
Dockerfile: update registry to v3.0.0-rc.4
2025-03-24 08:27:12 +09:00
Sebastiaan van Stijn
d01ee23c15 Dockerfile: update registry to v3.0.0-rc.4
release notes: https://github.com/distribution/distribution/releases/tag/v3.0.0-rc.4
full diff: https://github.com/distribution/distribution/compare/v3.0.0-rc.1...v3.0.0-rc.4

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-03-23 14:57:19 +01:00
Sebastiaan van Stijn
081987b647 Dockerfile: disable saving Golang telemetry in dev-container
Disable collecting local telemetry, as collected by Go and Delve;

- https://github.com/go-delve/delve/blob/v1.24.1/CHANGELOG.md#1231-2024-09-23
- https://go.dev/doc/telemetry#background

Telemetry is only collected, and not sent by default, so let's skip producing
it in the first place, as the dev-container is an ephemeral environment, and
this telemetry is not used.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-03-23 14:46:25 +01:00
Sebastiaan van Stijn
af14f3e7d3 Dockerfile: upgrade Delve to v1.24.1
Update to the latest version:

- https://github.com/go-delve/delve/releases/tag/v1.24.1
- https://github.com/go-delve/delve/blob/v1.24.1/CHANGELOG.md#1241-2025-03-05

Also update links to supported platforms. Delve v1.21.1 and higher now supports
linux/ppc64le (added in [delve@71f1220]), but this looks to be gated behind
an experimental build-tag. We could consider enabling this tag, but skipping
that for now.

[delve@71f1220]: 71f1220717

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-03-23 14:29:28 +01:00