Skip to content
Permalink

Comparing changes

This is a direct comparison between two commits made in this repository or its related repositories. View the default comparison for this range or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: docker/buildx
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 5d9187b1e0c4358a10f73c543adfcccaa6a3ed2e
Choose a base ref
..
head repository: docker/buildx
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 0d3986cfaec2b875c758edcb89f8224216933298
Choose a head ref
Showing with 18 additions and 0 deletions.
  1. +18 −0 Dockerfile
18 changes: 18 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -123,6 +123,24 @@ COPY --link --from=k3s /bin/kubectl /usr/bin/
COPY --link --from=buildkit /usr/bin/buildkitd /usr/bin/
COPY --link --from=buildkit /usr/bin/buildctl /usr/bin/
COPY --link --from=binaries /buildx /usr/bin/
COPY <<-"EOF" /entrypoint.sh
#!/bin/sh
set -e
# cgroup v2: enable nesting
# https://github.com/moby/moby/blob/v25.0.0/hack/dind#L59-L69
if [ -f /sys/fs/cgroup/cgroup.controllers ]; then
# move the processes from the root group to the /init group,
# otherwise writing subtree_control fails with EBUSY.
# An error during moving non-existent process (i.e., "cat") is ignored.
mkdir -p /sys/fs/cgroup/init
xargs -rn1 < /sys/fs/cgroup/cgroup.procs > /sys/fs/cgroup/init/cgroup.procs || :
# enable controllers
sed -e 's/ / +/g' -e 's/^/+/' < /sys/fs/cgroup/cgroup.controllers > /sys/fs/cgroup/cgroup.subtree_control
fi
exec "$@"
EOF
RUN chmod +x /entrypoint.sh
ENTRYPOINT ["/entrypoint.sh"]

FROM integration-test-base AS integration-test
COPY . .