444 Commits
Author SHA1 Message Date
CrazyMax 43d4cae9ee update alpine linux to 3.24
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2026-10-13 12:27:12 +02:00
Tonis Tiigi 5b31d5e317 lint: update to 2.14
Brings in support for go1.27

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2026-10-12 17:07:16 +02:00
Tonis Tiigi d4f5924b25 lint: support Go 1.27 validation
Build golangci-lint with Staticcheck v0.8.0-rc.1 to handle the Go 1.27
AST. Disable SA4023 because unsupported platform stubs cause false
positives during multiplatform linting.

Apply Go 1.27 formatting and replace the deprecated plain HTTP resolver
option.

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2026-10-12 17:07:16 +02:00
Sebastiaan van Stijn c3292e1abe update to go1.27
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-10-12 17:06:54 +02:00
CrazyMax 3090a253a1 dockerfile: update xx to 1.10.0
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2026-10-12 13:26:42 +02:00
CrazyMax 800394de56 ci: migrate vagrant to vmactions
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2026-10-07 18:04:34 +02:00
CrazyMax b1cbd8b0da db: support cancellable bbolt compaction
Gate transactions while copying live records and replacing the database, with separate drain and copy deadlines. Preserve database options and report successful replacement even when a subsequent operation fails.

Cover transaction draining, concurrent access, cancellation, replacement failures, and containerd metadata compatibility.

Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2026-09-29 16:02:25 +02:00
CrazyMax 10c5b17179 ci: distribute compatibility release tests
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2026-09-09 08:39:58 +02:00
Sebastiaan van Stijn 94dcaca630 update protoc to v3.14.0
Updating to the lowest release that includes [protobuf@dfab275], which
removed use of the github.com/golang/protobuf/ptypes/timestamp.Timestamp
type alias (deprecated).

[protobuf@dfab275]: https://github.com/protocolbuffers/protobuf/commit/dfab275eca9481b5de31122db6fc91b31db3382a

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-06-05 18:01:59 +02:00
CrazyMax 863c9dc919 ci: switch to bento/freebsd-14 vagrant box
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2026-06-05 13:06:39 +02:00
Tõnis Tiigi 550cf8b8b7 Merge pull request #6774 from tonistiigi/0513-dev-tools-updates
dev tools updates
2026-05-14 17:37:14 -07:00
Tonis Tiigi 64f364fd9f update protolint to v0.56.4
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2026-05-14 10:13:22 -07:00
Tonis Tiigi 2beb143001 update govulncheck to v1.3.0
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2026-05-14 10:13:21 -07:00
Tonis Tiigi 4ffb02ffcd update doctoc to v2.4.1
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2026-05-14 10:13:21 -07:00
Tonis Tiigi bd3608ddc9 lint: update golangci-lint to v2.12.2
Update golangci-lint and adjust code for new gosec diagnostics. Use
root-scoped filesystem operations where appropriate, preserve explicit
user path behavior for SSH keys, and avoid background contexts in
request-scoped cleanup paths.

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2026-05-14 10:13:15 -07:00
CrazyMax f3c6fef9b6 hack: switch to gomod-updates
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2026-05-13 13:52:17 +02:00
Jonathan A. Sternberg 937eaf88c8 feat: add log level option to buildkitd config
This adds a way to set the log level of buildkitd outside of using
`--debug` or `--trace` which allows increasing the log level rather than
only lowering it.

The `--debug` and `--trace` options are now deprecated along with the
configuration options. A warning will be printed to the log when they
are used.

Signed-off-by: Jonathan A. Sternberg <jonathan.sternberg@docker.com>
2026-05-06 13:55:07 -05:00
Tõnis Tiigi c1b5264bfd Merge pull request #6681 from tonistiigi/compat-version
solver: add compatibility-version support
2026-04-27 14:21:38 +02:00
Tonis Tiigi 95735c4ef9 ci: run compatibility releases via hack/test
Move compatibility-releases to a single job that reuses the
integration test image flow from the main test workflow.

Add hack/test support for injecting a buildkitd binary and add a
dedicated hack/test-compatibility-releases wrapper for the release
sweep.

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2026-04-14 19:16:07 -07:00
Jonathan A. Sternberg cf6b18e7c9 chore: prune unused protobuf files from googleapis
Signed-off-by: Jonathan A. Sternberg <jonathan.sternberg@docker.com>
2026-04-09 14:58:46 -05:00
CrazyMax 0e440708bf hack: print the README diff when doctoc validation fails
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2026-04-07 11:08:15 +02:00
Sebastiaan van Stijn 4eea931b28 Dockerfiles: pin doctoc to a fixed version
The v2.4.0 release had a minor regression and didn't detect the HTML
comments correctly;

```
diff --git a/README.md b/README.md
index 3f271be8625e..8ec4a7c5a421 100644
--- a/README.md
+++ b/README.md
@@ -42,6 +42,7 @@ Join `#buildkit` channel on [Docker Community Slack](https://dockr.ly/comm-slack

 <!-- START doctoc generated TOC please keep comment here to allow auto update -->
 <!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
+<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->

 - [Used by](#used-by)
 - [Quick start](#quick-start)
```

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-04-07 10:58:44 +02:00
CrazyMax 60f69ab411 hack: fall back when cgroup remount setup is unavailable
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2026-03-16 16:21:12 +01:00
Tonis Tiigi c33e1fa5cd chore: bump Go toolchain to 1.26
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2026-02-25 16:16:09 -08:00
Tõnis Tiigi 4a388e149d Merge pull request #6368 from marxarelli/review/unshare-cgroupns-entrypoint
dockerfile: run buildkitd within a cgroup namespace for cgroup v2
2026-02-24 09:30:39 -08:00
CrazyMax 93f176ade0 hack: write cgroup namespace progress message to stderr
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2026-02-24 17:17:58 +01:00
Tonis Tiigi 7f2cbc61ba http: add support for checksum requests for http sources
These requests allow computing additional checksum algorithms
for the payload of HTTP sources.

Optionally suffix can be passed that is added to payload. This
is needed to make validation of PGP signatures possible remotely.

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2026-02-20 08:13:32 -08:00
Dan Duvall 9a1bf2a83b dockerfile: run buildkitd within a cgroup namespace for cgroup v2
Introduce a new entrypoint script for the Linux image that, if cgroup v2
is in use, creates a new cgroup and mount namespace for buildkitd within
a new entrypoint using `unshare` and remounts `/sys/fs/cgroup` to
restrict its view of the unified cgroup hierarchy. This will ensure its
`init` cgroup and all OCI worker managed cgroups are kept beneath the
root cgroup of the initial entrypoint process.

When buildkitd is run in a managed environment like Kubernetes without
its own cgroup namespace (the default behavior of privileged pods in
Kubernetes where cgroup v2 is in use; see [cgroup v2 KEP][kep]), the OCI
worker will spawn processes in cgroups that are outside of the cgroup
hierarchy that was created for the buildkitd container, leading to
incorrect resource accounting and enforcement which in turn can cause
OOM errors and CPU contention on the node.

Example behavior without this change:

```console
root@k8s-node:/# cat /proc/$(pgrep -n buildkitd)/cgroup
0::/init
root@k8s-node:/# cat /proc/$(pgrep -n some-build-process)/cgroup
0::/buildkit/{runc-container-id}
```

Example behavior with this change:

```console
root@k8s-node:/# cat /proc/$(pgrep -n buildkitd)/cgroup
0::/kubepods/burstable/pod{pod-id}/{container-id}/init
root@k8s-node:/# cat /proc/$(pgrep -n some-build-process)/cgroup
0::/kubepods/burstable/pod{pod-id}/{container-id}/buildkit/{runc-container-id}
```

Note this was developed as an alternative approach to moby/buildkit#6343

[kep]: https://github.com/kubernetes/enhancements/tree/6d3210f7dd5d547c8f7f6a33af6a09eb45193cd7/keps/sig-node/2254-cgroup-v2#cgroup-namespace

Signed-off-by: Dan Duvall <dduvall@wikimedia.org>
2026-01-23 09:31:09 -08:00
CrazyMax 18ad342e57 Merge pull request #6460 from tonistiigi/golint-v2.8.0-update
hack: golangci v2.8.0 and gopls v0.38.0 update
2026-01-14 15:44:19 +01:00
Tonis Tiigi 5b6c89222b Dockerfile: fix version inconsistencies
Make sure Alpine, xx, Debian use same versions across Dockerfiles.

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2026-01-13 22:09:49 -08:00
Tonis Tiigi 55ac82cb58 hack: update gopls to v0.38.0
Currently it is not possible to update to more
recent version as modernize causes errors in generated code.

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2026-01-13 22:09:25 -08:00
Tonis Tiigi a8b83196f3 ci: update golangci to v2.8.0
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2026-01-13 22:09:20 -08:00
CrazyMax 0ad7a44d11 update alpine to 3.23
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2026-01-12 09:57:19 +01:00
CrazyMax 71068191db hack: use bake to build the dockerfile frontend
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2025-11-25 18:55:48 +01:00
Tonis Tiigi 04a38743bd hack: ssh fixtures generation
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2025-10-22 10:10:59 -07:00
Tonis Tiigi 1a3289a899 hack: gpg test fixtures generation
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2025-10-22 10:10:56 -07:00
CrazyMax 05fdd002b6 hack: use bake to build buildkit binaries
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2025-10-15 13:47:33 +02:00
CrazyMax 1fa57ee945 hack: use bake to build buildkit images
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2025-10-13 17:41:15 +02:00
Tõnis Tiigi 399c615e50 Merge pull request #6254 from crazy-max/hack-slsa-v1
hack: enable SLSA provenance v1 for buildkit and frontend images
2025-10-13 08:38:44 -07:00
CrazyMax 373f658d67 hack: fix no-cache-filter on release
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2025-10-01 10:26:55 +02:00
CrazyMax 61c3a9e1cd hack: enable SLSA provenance v1 for buildkit and frontend images
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2025-09-30 13:34:56 +02:00
Jonathan A. Sternberg 916074cfc5 hack: update hack/compose with newer otel collector
Modifies the hack/compose script to use a newer otel collector and try
to suppress miscellaneous logs when it fails to export traces. Disable
jaeger, prometheus, and grafana by default.

It also adds a metrics pipeline that goes to a nop exporter. This is
force the otel collector to start the metrics service and prevent an
error when buildkit exports metrics to the otel collector related to the
metrics service being missing.

Signed-off-by: Jonathan A. Sternberg <jonathan.sternberg@docker.com>
2025-09-23 10:49:24 -05:00
Jonathan A. Sternberg f4339fd00b tools: utilize the new tool functionality introduced in go 1.24
Removes the `tools/tools.go` file used as a hack to get `go.mod` to
track tools in favor of the new method introduced in go 1.24 of being
formally supported in the `go.mod` file. This will allow the tools to be
managed with the new `go get tool` and `go install tool` commands.

Signed-off-by: Jonathan A. Sternberg <jonathan.sternberg@docker.com>
2025-09-10 10:08:03 -05:00
Tonis Tiigi 04dbf0ba44 update go to 1.25
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2025-09-09 15:14:18 -07:00
CrazyMax 060be8484d hack: modernize-fix bake target
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2025-09-09 14:00:26 +02:00
CrazyMax e70ed65cbc update alpine to 3.22
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2025-06-27 11:34:46 +02:00
CrazyMax 628d5cb2cb dockerfile: update govulncheck to v1.1.4
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
2025-06-23 10:00:51 +02:00
Tonis Tiigi 9fcedf9807 update gopls to go1.24 compatible version
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2025-05-07 18:23:20 -07:00
Tonis Tiigi 3e5d4dcdf8 update to go1.24
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2025-05-07 16:59:15 -07:00
Tonis Tiigi f1f56c2b77 golangci-lint: v2 upgrade
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2025-05-02 12:19:17 -07:00