Commit graph

48036 commits

Author SHA1 Message Date
Sebastiaan van Stijn
2f28582b55
vendor: github.com/Microsoft/hcsshim v0.11.4
full diff: https://github.com/Microsoft/hcsshim/compare/v0.11.1...v0.11.4

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-11-19 13:12:22 +01:00
Sebastiaan van Stijn
75324c4cc8
Merge pull request #46814 from thaJeztah/update_authors
update authors and mailmap
2023-11-16 22:24:19 +01:00
Sebastiaan van Stijn
604f4eed65
Merge pull request #46819 from dmcgowan/c8d-fix-pull-by-digest
c8d: fix support for pull by digest
2023-11-16 20:00:07 +01:00
Sebastiaan van Stijn
847f3060d4
Merge pull request #46803 from thaJeztah/daemon_no_custom_opts
daemon/config: change DNSConfig.DNS to a []net.IP
2023-11-15 14:23:49 +01:00
Sebastiaan van Stijn
93fffa299c
Merge pull request #46818 from thaJeztah/fix_readme_example
client: update example in readme
2023-11-14 15:22:19 +01:00
Sebastiaan van Stijn
e6ae462268
Merge pull request #46812 from robmry/46810-vfs_faster_copy_of_hard_links
graphdriver/copy: faster copy of hard links
2023-11-14 13:18:30 +01:00
Sebastiaan van Stijn
8641d2da3b
client: update example in readme
The example still used the deprecated types.ContainerListOptions;
also slightly updated the example to show both stopped and running
containers, so that the example works even if no container is running.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-11-14 12:27:35 +01:00
Derek McGowan
0ab7267ae3
Fix support for pull by digest
Signed-off-by: Derek McGowan <derek@mcg.dev>
2023-11-13 21:38:51 -08:00
Sebastiaan van Stijn
ba46bda149
update authors and mailmap
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-11-13 22:12:58 +01:00
Sebastiaan van Stijn
f13d8c2026
Merge pull request #46724 from rhansen/host_ipv6
New `host_ipv6` bridge option to SNAT IPv6 connections
2023-11-13 21:50:17 +01:00
Rob Murray
a3fdad84ad graphdriver/copy: faster copy of hard links
The DirCopy() function in "graphdriver/copy/copy.go" has a special case for
skip file-attribute copying when making a hard link to an already-copied
file, if "copyMode == Hardlink". Do the same for copies of hard-links in
the source filesystem.

Significantly speeds up vfs's copy of a BusyBox filesystem (which
consists mainly of hard links to a single binary), making moby's
integration tests run more quickly and more reliably in a dev container.

Fixes #46810

Signed-off-by: Rob Murray <rob.murray@docker.com>
2023-11-13 18:22:03 +00:00
Sebastiaan van Stijn
6af7d6ea2d
Merge pull request #46808 from thaJeztah/vendor_runc_1.1.10
vendor: github.com/opencontainers/runc v1.1.10
2023-11-13 17:24:35 +01:00
Sebastiaan van Stijn
c89668f8e5
Merge pull request #46805 from thaJeztah/bump_runc_binary_1.1.10
update runc binary to v1.1.10
2023-11-13 16:58:28 +01:00
Sebastiaan van Stijn
b275f95f37
Merge pull request #46684 from smoser/fix/no-colors-in-check-config-to-file
contrib/check-config: Only add color if output is a terminal.
2023-11-13 16:33:43 +01:00
Sebastiaan van Stijn
9b02a84a5a
Merge pull request #46785 from rumpl/c8d-userns-commit
c8d: handle user namespace remapping on commit
2023-11-13 16:31:32 +01:00
Sebastiaan van Stijn
fb53da508f
vendor: github.com/opencontainers/runc v1.1.10
- full diff: https://github.com/opencontainers/runc/compare/v1.1.9...v1.1.10
- release notes: https://github.com/opencontainers/runc/releases/tag/v1.1.10

This is the tenth (and most likely final) patch release in the 1.1.z
release branch of runc. It mainly fixes a few issues in cgroups, and a
umask-related issue in tmpcopyup.

- Add support for `hugetlb.<pagesize>.rsvd` limiting and accounting.
  Fixes the issue of postgres failing when hugepage limits are set.
- Fixed permissions of a newly created directories to not depend on the value
  of umask in tmpcopyup feature implementation.
- libcontainer: cgroup v1 GetStats now ignores missing `kmem.limit_in_bytes`
  (fixes the compatibility with Linux kernel 6.1+).
- Fix a semi-arbitrary cgroup write bug when given a malicious hugetlb
  configuration. This issue is not a security issue because it requires a
  malicious config.json, which is outside of our threat model.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-11-13 16:26:29 +01:00
Sebastiaan van Stijn
15bcc707e6
update runc binary to v1.1.10
- full diff: https://github.com/opencontainers/runc/compare/v1.1.9...v1.1.10
- release notes: https://github.com/opencontainers/runc/releases/tag/v1.1.10

This is the tenth (and most likely final) patch release in the 1.1.z
release branch of runc. It mainly fixes a few issues in cgroups, and a
umask-related issue in tmpcopyup.

- Add support for `hugetlb.<pagesize>.rsvd` limiting and accounting.
  Fixes the issue of postgres failing when hugepage limits are set.
- Fixed permissions of a newly created directories to not depend on the value
  of umask in tmpcopyup feature implementation.
- libcontainer: cgroup v1 GetStats now ignores missing `kmem.limit_in_bytes`
  (fixes the compatibility with Linux kernel 6.1+).
- Fix a semi-arbitrary cgroup write bug when given a malicious hugetlb
  configuration. This issue is not a security issue because it requires a
  malicious config.json, which is outside of our threat model.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-11-13 16:01:02 +01:00
Sebastiaan van Stijn
84036d3e18
daemon/config: change DNSConfig.DNS to a []net.IP
Use a strong type for the DNS IP-addresses so that we can use flags.IPSliceVar,
instead of implementing our own option-type and validation.

Behavior should be the same, although error-messages have slightly changed:

Before this patch:

    dockerd --dns 1.1.1.1oooo --validate
    Status: invalid argument "1.1.1.1oooo" for "--dns" flag: 1.1.1.1oooo is not an ip address
    See 'dockerd --help'., Code: 125

    cat /etc/docker/daemon.json
    {"dns": ["1.1.1.1"]}

    dockerd --dns 2.2.2.2 --validate
    unable to configure the Docker daemon with file /etc/docker/daemon.json: the following directives are specified both as a flag and in the configuration file: dns: (from flag: [2.2.2.2], from file: [1.1.1.1])

    cat /etc/docker/daemon.json
    {"dns": ["1.1.1.1oooo"]}

    dockerd --validate
    unable to configure the Docker daemon with file /etc/docker/daemon.json: merged configuration validation from file and command line flags failed: 1.1.1.1ooooo is not an ip address

With this patch:

    dockerd --dns 1.1.1.1oooo --validate
    Status: invalid argument "1.1.1.1oooo" for "--dns" flag: invalid string being converted to IP address: 1.1.1.1oooo
    See 'dockerd --help'., Code: 125

    cat /etc/docker/daemon.json
    {"dns": ["1.1.1.1"]}

    dockerd --dns 2.2.2.2 --validate
    unable to configure the Docker daemon with file /etc/docker/daemon.json: the following directives are specified both as a flag and in the configuration file: dns: (from flag: [2.2.2.2], from file: [1.1.1.1])

    cat /etc/docker/daemon.json
    {"dns": ["1.1.1.1oooo"]}

    dockerd --validate
    unable to configure the Docker daemon with file /etc/docker/daemon.json: invalid IP address: 1.1.1.1oooo

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-11-13 12:22:51 +01:00
Sebastiaan van Stijn
34e923e3e3
Merge pull request #46801 from thaJeztah/improve_ValidateIPAddress
opts: ValidateIPAddress: improve error, godoc, and tests
2023-11-13 12:22:38 +01:00
Sebastiaan van Stijn
1eadfb0e28
opts: ValidateIPAddress: improve error, godoc, and tests
- document accepted values
- add test-coverage for the function's behavior (including whitespace handling),
  and use sub-tests.
- improve error-message to use uppercase for "IP", and to use a common prefix.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-11-11 15:31:19 +01:00
Sebastiaan van Stijn
3b423ea778
Merge pull request #46799 from thaJeztah/bump_go_connections
vendor: github.com/docker/go-connections fa09c952e3ea (v0.5.0-dev)
2023-11-11 00:49:56 +01:00
Sebastiaan van Stijn
981a878cf5
vendor: github.com/docker/go-connections fa09c952e3ea (v0.5.0-dev)
0b8c1f4e07...fa09c952e3

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-11-10 23:23:37 +01:00
Tianon Gravi
7c8d02d1bc
Merge pull request #46797 from cpuguy83/fix_missing_scope
Fix missing import for "scope" package
2023-11-09 16:15:16 -08:00
Brian Goff
f0b89e63b9 Fix missing import for "scope" package
I believe this happened due to conflicting PR's that got merged without
CI re-running between them.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2023-11-09 22:48:01 +00:00
Brian Goff
63b2a2138d
Merge pull request #41084 from thaJeztah/40495_update_goconnections_negotiate
Bump go-connections for TLS 1.3 support
2023-11-09 14:33:18 -08:00
Brian Goff
99638f5f76
Merge pull request #46713 from p-fruck/docs/api-network-connect-403 2023-11-09 12:48:59 -08:00
Sebastiaan van Stijn
774e677cc8
Merge pull request #46781 from kb2ma/doc-swagger-port
Update API README to include port in URL for locally built Swagger docs
2023-11-09 20:34:22 +01:00
Brian Goff
524eef5d75
Merge pull request #46681 from corhere/libn/datastore-misc-cleanups 2023-11-09 11:31:30 -08:00
Sebastiaan van Stijn
5bff90cea2
Merge pull request #46789 from akerouanton/updateSvcRecord-early-return
libnet: early-return from updateSvcRecord if no addr available
2023-11-09 14:14:55 +01:00
Albin Kerouanton
d47b3ef4c9
libnet: early return from updateSvcRecord if no addr available
Early return if the iface or its address is nil to make the whole
function slightly easier to read.

Signed-off-by: Albin Kerouanton <albinker@gmail.com>
2023-11-08 20:45:15 +01:00
Albin Kerouanton
7e66d9900c
Merge pull request #46788 from akerouanton/container-rename-refactor
daemon: ContainerRename: use named error-return
2023-11-08 20:37:22 +01:00
Albin Kerouanton
f5a611a74c
daemon: ContainerRename: use named error-return
It's used in various defers, but was using `err` as name, which can be
confusing, and increases the risk of accidentally shadowing the error.

Signed-off-by: Albin Kerouanton <albinker@gmail.com>
2023-11-08 18:53:13 +01:00
Sam Whited
8074e7a437
Bump go-connections for TLS 1.3 support
Fixes 40495

Signed-off-by: Sam Whited <sam@samwhited.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-11-08 17:58:50 +01:00
Sebastiaan van Stijn
5504ef7a84
Merge pull request #46784 from rumpl/image-builder-cleanup
c8d: cleanup imports in the image builder file
2023-11-08 17:27:52 +01:00
Sebastiaan van Stijn
ea729aea4a
Merge pull request #46577 from RachitSharma2001/46576-dockerimagelsuntil
Add until filter to docker image ls
2023-11-08 16:58:08 +01:00
Sebastiaan van Stijn
587d509ddd
Merge pull request #46777 from thaJeztah/fix_redirects
docs/api: update redirect metadata for hugo
2023-11-08 14:19:59 +01:00
Djordje Lukic
d06af368ad
c8d: "unremap" the user namespace on commit
We remap the snapshot when we create a container, we have to to the
inverse when we commit the container into an image

Signed-off-by: Djordje Lukic <djordje.lukic@docker.com>
2023-11-08 13:28:45 +01:00
Djordje Lukic
a7acfffea6
test: Add a test for userns remapped daemon commit
The files in an image created by a commit should have the right uid and gid set

Signed-off-by: Djordje Lukic <djordje.lukic@docker.com>
2023-11-08 12:33:03 +01:00
Djordje Lukic
876d4e5484
c8d: cleanup imports in the image builder file
Signed-off-by: Djordje Lukic <djordje.lukic@docker.com>
2023-11-08 12:31:03 +01:00
Rachit Sharma
7995e3288f
Add until filter to docker image ls
Signed-off-by: Rachit Sharma <rachitsharma613@gmail.com>

add handling for multiple filters

Signed-off-by: Rachit Sharma <rachitsharma613@gmail.com>

Update integration/image/list_test.go

Co-authored-by: Cory Snider <corhere@gmail.com>
Signed-off-by: Rachit Sharma <rachitsharma613@gmail.com>

Add documentation of filter

Signed-off-by: Rachit Sharma <rachitsharma613@gmail.com>

Update integration/image/list_test.go

Co-authored-by: Cory Snider <corhere@gmail.com>
Signed-off-by: Rachit Sharma <rachitsharma613@gmail.com>

Fix bug with CommitOptions

Signed-off-by: Rachit Sharma <rachitsharma613@gmail.com>

add wrapping of text to 80 chars

Signed-off-by: Rachit Sharma <rachitsharma613@gmail.com>
2023-11-08 12:12:23 +01:00
Sebastiaan van Stijn
0c0943bcdf
Merge pull request #46783 from thaJeztah/fix_test
integration/networking: fix TestBridgeICC
2023-11-08 12:11:40 +01:00
Sebastiaan van Stijn
58785c2932
integration/networking: fix TestBridgeICC
This test broke in 98323ac114.

This commit renamed WithMacAddress into WithContainerWideMacAddress.
This helper sets the MacAddress field in container.Config. However, API
v1.44 now ignores this field if the NetworkMode has no matching entry in
EndpointsConfig.

This fix uses the helper WithMacAddress and specify for which
EndpointConfig the MacAddress is specified.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Signed-off-by: Albin Kerouanton <albinker@gmail.com>
2023-11-08 10:23:24 +01:00
Sebastiaan van Stijn
c14694a424
Merge pull request #46779 from dmcgowan/c8d-default-auth-domain
Default the auth config domain to the target image domain
2023-11-07 16:44:31 +01:00
Sebastiaan van Stijn
49cea49cfa
Merge pull request #45905 from akerouanton/endpoint-specific-mac-address
api: Add a field MacAddress to EndpointSettings
2023-11-07 16:37:27 +01:00
Ken Bannister
6979503a85 Include port in URL for locally built Swagger docs
Signed-off-by: Ken Bannister <kb2ma@runbox.com>
2023-11-07 08:07:32 -05:00
Derek McGowan
755f008c1e
Default the auth config domain to the target image domain
When server address is not provided with the auth configuration,
use the domain from the image provided with the auth.

Signed-off-by: Derek McGowan <derek@mcg.dev>
2023-11-06 17:02:18 -08:00
Sebastiaan van Stijn
796da163f9
Merge pull request #46778 from corhere/libc8d/revert-serialize-exec-starts-workaround
Revert "libcontainerd: work around exec start bug in c8d"
2023-11-06 21:12:39 +01:00
Cory Snider
7d9d601e6d project: document supported containerd versions
We only support containerd versions which have fixes for
https://github.com/containerd/containerd/issues/8557.

Signed-off-by: Cory Snider <csnider@mirantis.com>
2023-11-06 13:43:18 -05:00
Cory Snider
29ac09ee9d Revert "libcontainerd: work around exec start bug in c8d"
The workaround is no longer required. The bug has been fixed in stable
versions of all supported containerd branches.

This reverts commit fb7ec1555c.

Signed-off-by: Cory Snider <csnider@mirantis.com>
2023-11-06 13:26:44 -05:00
Sebastiaan van Stijn
c1a289e05a
docs/api: update redirect metadata for hugo
docs.docker.com switched from Jekyll to Hugo, which uses "aliases"
instead of "redirect_from".

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-11-06 18:16:47 +01:00