3 foreground { redirfd -w 2 /dev/null mkdir -p /run/uncaught-logs }
4 if { chown s6-logs:s6-logs /run/uncaught-logs }
5 if { chmod 2700 /run/uncaught-logs }
6 foreground { redirfd -w 2 /dev/null mkdir -p ${1}/.s6-svscan ${1}/s6-svscan-log }
7 foreground { redirfd -w 2 /dev/null ln -sf /bin/false ${1}/.s6-svscan/crash }
10 redirfd -w 1 ${1}/.s6-svscan/finish
11 heredoc 0 "#!/bin/execlineb -P\ns6-svc -x -- \"${1}/s6-svscan-log\"\n"
14 if { chmod 0755 ${1}/.s6-svscan/finish }
15 foreground { redirfd -w 2 /dev/null mkfifo -m 0600 ${1}/s6-svscan-log/fifo }
18 redirfd -w 1 ${1}/s6-svscan-log/run
19 heredoc 0 "#!/bin/execlineb -P
20 redirfd -w 2 /dev/console
24 s6-log t /run/uncaught-logs\n"
27 if { chmod 0755 ${1}/s6-svscan-log/run }
29 redirfd -r 0 /dev/null
30 redirfd -wnb 1 ${1}/s6-svscan-log/fifo