Skip to main content

Kiosk Machine

This is a work in progress i.e. I am starting with a locked-down account and working towards a final kiosk deployment.

I am trying to achieve this using PoPOS! with Firefox as the default browser, using duckduckgo as the start-up page and default search engine. The duckduckgo Firefox extension is also installed.

Create a script to run Firefox in full screen mode, opening duckduckgo's homepage in private mode.

I also set the Firefox settings so that no passwords are saved and everything is cleared on exit.

#!/bin/bash
firefox "https://www.duckduckgo.com" --private-window &
sleep 2
xdotool key F11 #xdotool needs to ne installed for this to work

Have the laptop reboot every 10min

#!/bin/bash

# Get idle time in milliseconds
idle_time=$(xprintidle) #xprintidle needs to be installed

# Convert idle time to minutes
idle_minutes=$((idle_time / 60000))

# Check if idle time is greater than or equal to 10 minutes
if [ "$idle_minutes" -ge 10 ]; then
    sudo reboot
fi

Both the above scripts need to be made executable and stored in /user/usr/local/bin.

chmod +x filename.sh

We now need to set up the cron job to check for the idle time

crontab -e

and add the following line so that it runs every minute

* * * * * /path/to/idle-reboot.sh #path and file name of idle script

Using OverlayRoot  any changes will be lost when the system reboots.

sudo apt-get install overlayroot

then

sudo nano /etc/overlayroot.conf

and add

overlayroot="tmpfs"

Now reboot.

To disable overlayroot, comment out the above line

#overlayroot="tmpfs"

and then run

sudo update-initramfs -u

Now reboot