ayaports/user/qubes-vm-core/qubes-core-early.openrc

40 lines
959 B
Text
Raw Normal View History

2023-03-08 01:57:30 +00:00
#!/sbin/openrc-run
name=$RC_SVCNAME
error_log=/var/log/qubes/$RC_SVCNAME.log
depend() {
need qubes-sysinit
need qubes-db
}
start_pre() {
checkpath --directory --owner $command_user:qubes --mode 0775 \
/var/lib/qubes
}
start()
{
echo "Enabling transparent hugepages" | tee -a "$error_log"
echo "madvise" > /sys/kernel/mm/transparent_hugepage/enabled
echo "Setting up early config" | tee -a "$error_log"
/usr/lib/qubes/init/qubes-early-vm-config.sh 2>&1 | tee -a "$error_log"
echo "Adjusting root filesystem size:" | tee -a "$error_log"
/usr/lib/qubes/init/resize-rootfs-if-needed.sh 2>&1 | tee -a "$error_log"
echo "Setting up Qubes persistent file systems:" 2>&1 | tee -a "$error_log"
/usr/lib/qubes/init/mount-dirs.sh 2>&1 | tee -a "$error_log"
echo "Executing Qubes random seed scripts:" | tee -a "$error_log"
/usr/lib/qubes/init/qubes-random-seed.sh 2>&1 | tee -a "$error_log"
}
stop()
{
return 0
}