spiegel_podman/vendor/github.com/containers/common/pkg
Valentin Rothberg 6293ec2e2d fix handling of static/volume dir
The processing and setting of the static and volume directories was
scattered across the code base (including c/common) leading to subtle
errors that surfaced in #19938.

There were multiple issues that I try to summarize below:

 - c/common loaded the graphroot from c/storage to set the defaults for
   static and volume dir.  That ignored Podman's --root flag and
   surfaced in #19938 and other bugs.  c/common does not set the
   defaults anymore which gives Podman the ability to detect when the
   user/admin configured a custom directory (not empty value).

 - When parsing the CLI, Podman (ab)uses containers.conf structures to
   set the defaults but also to override them in case the user specified
   a flag.  The --root flag overrode the static dir which is wrong and
   broke a couple of use cases.  Now there is a dedicated field for in
   the "PodmanConfig" which also includes a containers.conf struct.

 - The defaults for static and volume dir and now being set correctly
   and adhere to --root.

 - The CONTAINERS_CONF_OVERRIDE env variable has not been passed to the
   cleanup process.  I believe that _all_ env variables should be passed
   to conmon to avoid such subtle bugs.

Overall I find that the code and logic is scattered and hard to
understand and follow.  I refrained from larger refactorings as I really
just want to get #19938 fixed and then go back to other priorities.

https://github.com/containers/common/pull/1659 broke three pkg/machine
tests.  Those have been commented out until getting fixed.

Fixes: #19938
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-09-25 14:14:30 +02:00
..
apparmor vendor of containers/(common, storage, image) 2023-09-11 13:52:23 -04:00
auth vendor of containers/common 2023-09-20 08:39:49 -04:00
capabilities Vendor in containers/(storage,image, common, buildah) 2022-07-18 10:42:04 -04:00
cgroups bump c/common to latest main 2023-09-12 16:03:40 +02:00
cgroupv2 vendor c/common@0ededd18a1 2022-03-18 15:18:30 +01:00
chown Vendor in containers/(storage,image, common, buildah) 2022-07-18 10:42:04 -04:00
completion vendor in latests containers/common 2023-06-21 15:10:25 +08:00
config fix handling of static/volume dir 2023-09-25 14:14:30 +02:00
detach vendor of containers/common 2023-09-20 08:39:49 -04:00
download system df: fix image-size calculations 2022-10-19 11:20:41 +02:00
filters vendor of containers/common 2023-09-20 08:39:49 -04:00
flag vendor of containers/(common, storage, image) 2023-09-11 13:52:23 -04:00
hooks make image listing more resilient 2023-06-26 16:34:26 +02:00
machine system df: fix image-size calculations 2022-10-19 11:20:41 +02:00
manifests vendor in latests containers/common 2023-06-21 15:10:25 +08:00
netns vendor containers/common@e27c30ee9b 2023-03-30 09:34:32 +02:00
parse system df: fix image-size calculations 2022-10-19 11:20:41 +02:00
password vendor of containers/common 2023-09-20 08:39:49 -04:00
report vendor of containers/(common, storage, image) 2023-09-11 13:52:23 -04:00
resize use c/common code for resize and CopyDetachable 2022-07-06 16:57:07 +02:00
retry vendor of containers/(common, storage, image) 2023-09-11 13:52:23 -04:00
rootlessport use libnetwork/slirp4netns from c/common 2023-06-22 11:16:13 +02:00
seccomp Vendor in containers/(storage,image, common, buildah) 2022-07-18 10:42:04 -04:00
secrets vendor of containers/(common, storage, image) 2023-09-11 13:52:23 -04:00
servicereaper fix(deps): update module github.com/containers/buildah to v1.31.0 2023-07-01 00:26:07 +00:00
signal vendor c/common@0ededd18a1 2022-03-18 15:18:30 +01:00
ssh vendor of containers/(common, storage, image) 2023-09-11 13:52:23 -04:00
subscriptions vendor of containers/(common, storage, image) 2023-09-11 13:52:23 -04:00
supplemented vendor in latests containers/common 2023-06-21 15:10:25 +08:00
sysinfo history: correctly set tags 2023-05-02 16:21:09 +02:00
timetype system df: fix image-size calculations 2022-10-19 11:20:41 +02:00
umask Update c/common and avoid setting umask 2023-04-27 08:59:44 +02:00
util vendor of containers/common 2023-09-20 08:39:49 -04:00
version vendor of containers/common 2023-09-20 08:39:49 -04:00