After reading a lot of other questions regarding kiosk mode, I'm using matchbox window manager to launch chromium on my pi that is booting raspbian.
I'm started using an older script that was mentioned (
S99xkiosk ) which wasn't really written to the update-rc.d standards, and was causing errors like:
update-rc.d: error: insserv rejected the script header
When I would run
apt-get update or
dpkg --configure -a
So I've rewritten the script and I think it is working pretty well:
#!/bin/sh # # kiosk initscript # ### BEGIN INIT INFO # Provides: kiosk # Required-Start: $local_fs $remote_fs x11-common # Default-Start: 4 # Required-Stop: # Default-Stop: # Short-Description: Starts the Chrome Kiosk # Description: This scripts starts the chrome kiosk ### END INIT INFO # launch the kiosk script as the pi user su -c /home/pi/kiosk.sh - pi # give the system a chance to be rescued via SSH in case of an error sleep 30 # but otherwise we'll assume that chrome should not have exited and reboot the system shutdown now -r
The script is installed at
/etc/init.d/kiosk and I want it to be the last thing that runs, so I'd like it to be symlinked as
I can create this symlink manually, but I'd like to know if it is possible to do it with
I've read the
man page for
update-rc.d and tried the examples, the closest I can get is:
update-rc.d kiosk start 20 4 .
But that seems to put it at
/etc/rc4.d/S01kiosk and then
20 doesn't seem to have any effect.
Is there something wrong with my
init.d script or am I using
ps: The intention of the script is to be the last thing that loads - because, as I understand, the
init scripts are blocking - so we want everything else loaded first. Then it runs the script that launches chromium as the foreground process, and we'll reboot the system in the case of a browser crash (where the script would continue executing)
That's why I'd like the init script to be symlinked as