Skip to content

Instantly share code, notes, and snippets.

@karl-gustav
Last active September 21, 2018 13:20
Show Gist options
  • Save karl-gustav/301a9ff5e6f1e89591ffaeef84593dca to your computer and use it in GitHub Desktop.
Save karl-gustav/301a9ff5e6f1e89591ffaeef84593dca to your computer and use it in GitHub Desktop.
How to install kiosk screen raspberry pi

Put 2018-06-27-raspbian-stretch-lite.img on the SD card

Enable ssh:

sudo systemctl enable ssh

Update and install dependencies:

sudo apt-get update
sudo apt-get install \
    sudo \
    xorg \
    chromium-browser \
    openbox \
    lightdm

Edit /etc/lightdm/lightdm.conf and paste at the top:

# My stuff:

[SeatDefaults]
autologin-user=kiosk-user
user-session=openbox
xserver-command=X -nocursor

Login as kiosk user:

sudo useradd -m kiosk-user
sudo su kiosk-user
mkdir -p $HOME/.config/openbox

Edit $HOME/.config/openbox/autostart and paste

# Suppress screensaver start attempts and autoblanking
xset -dpms &
xset s off &

chromium-browser \
  --no-first-run \
  --disable \
  --disable-translate \
  --disable-infobars \
  --disable-suggestions-service \
  --disable-save-password-bubble \
  --start-maximized \
  --incognito \
  --kiosk "http://example.com" &

You might also want to fix the automatic setting of the system clock to make the screen show the correct time: https://gist.github.com/karl-gustav/4918d46d8305868fa7e545a25ce537b2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment