-
Notifications
You must be signed in to change notification settings - Fork 18.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs: contributing docs update for cross comp
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
- Loading branch information
Showing
2 changed files
with
25 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
The `Dockerfile` supports building and cross compiling docker daemon and extra | ||
tools using [Docker Buildx](https://github.com/docker/buildx) and [BuildKit](https://github.com/moby/buildkit). | ||
A [bake definition](https://docs.docker.com/build/bake/file-definition/) named | ||
`docker-bake.hcl` is in place to ease the build process: | ||
|
||
```shell | ||
# build binaries for the current host platform | ||
# output to ./bundles/binary by default | ||
docker buildx bake | ||
|
||
# build binaries for the current host platform | ||
# output to ./bin | ||
DESTDIR=./bin docker buildx bake | ||
|
||
# build dynamically linked binaries | ||
# output to ./bundles/dynbinary by default | ||
DOCKER_STATIC=0 docker buildx bake | ||
|
||
# build binaries for all supported platforms | ||
docker buildx bake binary-cross | ||
|
||
# build binaries for a specific platform | ||
docker buildx bake --set *.platform=linux/arm64 | ||
``` |