Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tidy up runsvdir symlinks during runit phase 1, so that the preparing… #52

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions core-services/99-cleanup.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,16 @@
# vim: set ts=4 sw=4 et:

# runsvchdir chokes if the current and/or previous symlinks are broken
if [ -e /etc/runit/runsvdir/previous ]; then
rm /etc/runit/runsvdir/previous
fi
if [ -e /etc/runit/runsvdir/current ]; then
rm /etc/runit/runsvdir/current
fi
# Set the initial runlevel to 'default', even if a different one
# is being selected through the kernel command line (see /etc/runit/2)
ln -s default /etc/runit/runsvdir/current

if [ ! -e /var/log/wtmp ]; then
install -m0664 -o root -g utmp /dev/null /var/log/wtmp
fi
Expand Down