446d4138ed
full diff: https://github.com/moby/sys/compare/capability/v0.3.0...capability/v0.4.0 Added * New separate API for ambient ([GetAmbient], [SetAmbient], [ResetAmbient]) and bound ([GetBound], [DropBound]) capabilities, modelled after libcap. Fixed * [Apply] now returns an error if called for non-zero `pid`. Before this change, it could silently change some capabilities of the current process, instead of the one identified by the `pid`. * Fixed tests that change capabilities to be run in a separate process. * Other improvements in tests. Changed * Use raw syscalls (which are slightly faster). * Most tests are now limited to testing the public API of the package. * Simplify parsing /proc/*pid*/status, add a test case. * Optimize the number of syscall to set ambient capabilities in Apply by clearing them first; add a test case. * Better documentation for [Apply], [NewFile], [NewFile2], [NewPid], [NewPid2]. Removed * `.golangci.yml` and `.codespellrc` are no longer part of the package. <!-- Doc links (please keep sorted). --> [Apply]: https://pkg.go.dev/github.com/moby/sys/capability#Capabilities.Apply [DropBound]: https://pkg.go.dev/github.com/moby/sys/capability#DropBound [GetAmbient]: https://pkg.go.dev/github.com/moby/sys/capability#GetAmbient [GetBound]: https://pkg.go.dev/github.com/moby/sys/capability#GetBound [LastCap]: https://pkg.go.dev/github.com/moby/sys/capability#LastCap [ListKnown]: https://pkg.go.dev/github.com/moby/sys/capability#ListKnown [ListSupported]: https://pkg.go.dev/github.com/moby/sys/capability#ListSupported [List]: https://pkg.go.dev/github.com/moby/sys/capability#List [NewFile2]: https://pkg.go.dev/github.com/moby/sys/capability#NewFile2 [NewFile]: https://pkg.go.dev/github.com/moby/sys/capability#NewFile [NewPid2]: https://pkg.go.dev/github.com/moby/sys/capability#NewPid2 [NewPid]: https://pkg.go.dev/github.com/moby/sys/capability#NewPid [ResetAmbient]: https://pkg.go.dev/github.com/moby/sys/capability#ResetAmbient [SetAmbient]: https://pkg.go.dev/github.com/moby/sys/capability#SetAmbient Signed-off-by: Sebastiaan van Stijn <github@gone.nl> |
||
---|---|---|
.github | ||
cli | ||
cli-plugins | ||
cmd/docker | ||
contrib/completion | ||
dockerfiles | ||
docs | ||
e2e | ||
experimental | ||
hack/otel | ||
internal/test | ||
man | ||
opts | ||
pkg/kvfile | ||
scripts | ||
service/logs | ||
templates | ||
vendor | ||
.dockerignore | ||
.gitattributes | ||
.gitignore | ||
.golangci.yml | ||
.mailmap | ||
AUTHORS | ||
CONTRIBUTING.md | ||
Dockerfile | ||
LICENSE | ||
MAINTAINERS | ||
Makefile | ||
NOTICE | ||
README.md | ||
SECURITY.md | ||
TESTING.md | ||
VERSION | ||
codecov.yml | ||
docker-bake.hcl | ||
docker.Makefile | ||
vendor.mod | ||
vendor.sum |
README.md
Docker CLI
About
This repository is the home of the Docker CLI.
Development
docker/cli
is developed using Docker.
Build CLI from source:
docker buildx bake
Build binaries for all supported platforms:
docker buildx bake cross
Build for a specific platform:
docker buildx bake --set binary.platform=linux/arm64
Build dynamic binary for glibc or musl:
USE_GLIBC=1 docker buildx bake dynbinary
Run all linting:
docker buildx bake lint shellcheck
Run test:
docker buildx bake test
List all the available targets:
make help
In-container development environment
Start an interactive development environment:
make -f docker.Makefile shell
Legal
Brought to you courtesy of our legal counsel. For more context, see the NOTICE document in this repo.
Use and transfer of Docker may be subject to certain restrictions by the United States and other governments.
It is your responsibility to ensure that your use and/or transfer does not violate applicable laws.
For more information, see https://www.bis.doc.gov
Licensing
docker/cli is licensed under the Apache License, Version 2.0. See LICENSE for the full license text.