indextext.html: add notice about upcoming ssh host key change
[girocco.git] / toolbox / run-jobd.sh
blob0d604624ddd67b3fced3f748e296612f823c9cc6
1 #!/bin/sh
3 DEFAULTOPTS="-q -P --kill-after 1000"
5 test -n "$PATH" || PATH="$(/usr/bin/getconf PATH)"
6 export PATH
7 cd /
8 shbin=@shbin@
10 exec_login_shell() {
11 # set arg 0 to have a leading '-' to force a login shell since
12 # the -l option is shell-specific. All shells must understand -i.
13 exec @perlbin@ -e 'my $b=shift; exec $b @ARGV or die "Can\047t exec \"$b\": $!\n"' "${SHELL:-$shbin}" "-$(basename "${SHELL:-$shbin}")" -i
16 if [ "$1" = "--shell" ]; then
17 shift
18 trap 'trap - HUP INT QUIT ABRT PIPE ALRM TERM TSTP TTIN TTOU BUS ILL SEGV FPE TRAP XCPU XFSZ; exec_login_shell' EXIT
19 trap '' HUP INT QUIT ABRT PIPE ALRM TERM TSTP TTIN TTOU BUS ILL SEGV FPE TRAP XCPU XFSZ
21 trap - HUP INT QUIT ABRT PIPE ALRM TERM TSTP TTIN TTOU BUS ILL SEGV FPE TRAP XCPU XFSZ
22 /usr/bin/nice -n 18 @perlbin@ -I@basedir@/jobd @basedir@/jobd/jobd.pl --same-pid $DEFAULTOPTS "$@"
24 exit
26 exec /usr/bin/nice -n 18 @perlbin@ -I@basedir@/jobd @basedir@/jobd/jobd.pl --same-pid $DEFAULTOPTS "$@"