deploy: Ignore sockets, fifos in /etc during merge
authorColin Walters <walters@verbum.org>
Thu, 30 Sep 2021 19:53:18 +0000 (15:53 -0400)
committerColin Walters <walters@verbum.org>
Fri, 1 Oct 2021 15:28:11 +0000 (11:28 -0400)
commite6a560b40797324aa8b90e7100c6d50bff91f14d
tree6a25a80b7ae59c7d33463338111786440743cb48
parent5bf4b1dabc12d6caee4f4899c9388a48bb4a72a3
deploy: Ignore sockets, fifos in /etc during merge

https://bugzilla.redhat.com/show_bug.cgi?id=1945274 is an issue where a privileged
kubernetes daemonset is writing a socket into `/etc`.  This makes ostree upgrades barf.

Now, they should clearly move it to `/run`.  However, one option is for us to
just ignore it instead of erroring out.  Some brief investigation shows that
e.g. `git add somesocket` is a silent no-op, which is an argument in favor of ignoring it.

Closes: https://github.com/ostreedev/ostree/issues/2446
src/libostree/ostree-sysroot-deploy.c
tests/kolainst/destructive/staged-deploy.sh
tests/test-admin-deploy-etcmerge-cornercases.sh