debian-atomic-system-files/ostree-dracut/modules.d/98ostree/module-setup.sh
2025-09-01 14:05:34 -07:00

28 lines
768 B
Bash

#!/usr/bin/bash
installkernel() {
instmods erofs overlay
}
check() {
if [[ -x $systemdutildir/systemd ]] && [[ -x /usr/lib/ostree/ostree-prepare-root ]]; then
return 255
fi
return 1
}
depends() {
return 0
}
install() {
dracut_install /usr/lib/ostree/ostree-prepare-root
for r in /usr/lib /etc; do
if test -f "$r/ostree/prepare-root.conf"; then
inst_simple "$r/ostree/prepare-root.conf"
fi
done
inst_simple "${systemdsystemunitdir}/ostree-prepare-root.service"
mkdir -p "${initdir}${systemdsystemconfdir}/initrd-root-fs.target.wants"
ln_r "${systemdsystemunitdir}/ostree-prepare-root.service" \
"${systemdsystemconfdir}/initrd-root-fs.target.wants/ostree-prepare-root.service"
}