Skip to content
This repository has been archived by the owner on May 24, 2024. It is now read-only.

Commit

Permalink
basic-fixes: Tweak /usr/lib/tmpfiles.d/provision.conf
Browse files Browse the repository at this point in the history
This ensures that systemd's creation of `/root` works instead
of falling back to what we have in
`/usr/lib/tmpfiles.d/rpm-ostree-0-integration.conf` for
`d /var/roothome 0700 root root -` which in turn ensures
that both the credential values as well as bootc's injection
of a tmpfiles.d snippet for root SSH key works.

containers/bootc#358
Signed-off-by: Colin Walters <[email protected]>
  • Loading branch information
cgwalters committed Feb 28, 2024
1 parent 788f57e commit 99dab23
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions tier-0/basic-fixes.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,10 @@ postprocess:
if test '!' -f /usr/lib/systemd/system/local-fs.target.wants/tmp.mount; then
ln -sf ../tmp.mount /usr/lib/systemd/system/local-fs.target.wants
fi
# See https://github.com/containers/bootc/issues/358
# basically systemd-tmpfiles doesn't follow symlinks; ordinarily our
# tmpfiles.d unit for `/var/roothome` is fine, but this actually doesn't
# work if we want to use tmpfiles.d to write to `/root/.ssh` because
# tmpfiles gives up on that before getting to `/var/roothome`.
sed -ie 's, /root, /var/roothome,'' /usr/lib/tmpfiles.d/provision.conf

0 comments on commit 99dab23

Please sign in to comment.