Skip to content

Commit

Permalink
coreos-ignition-setup-user: Remount before writing to /usr
Browse files Browse the repository at this point in the history
Thanks to Ignaz Forster <[email protected]>
Fixes: #3031
  • Loading branch information
travier committed Jul 29, 2024
1 parent 62a6078 commit de81bec
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,16 @@ copy_file_if_exists() {
fi
}

destination=/usr/lib/ignition
mkdir -p $destination

# systemd v256 now runs the initrd with ProtectSystem=yes, which makes /usr
# read-only. Just remount it rw until we have:
# https://github.com/coreos/ignition/issues/1891
if [ ! -w /usr ]; then
mount -o rw,remount /usr
fi

destination=/usr/lib/ignition
mkdir -p $destination

if is-live-image; then
# Live image. If the user has supplied a config.ign via an appended
# initrd, put it in the right place.
Expand Down

0 comments on commit de81bec

Please sign in to comment.