Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@obstschale
Last active December 21, 2020 18:36
Show Gist options
  • Star 4 You must be signed in to star a gist
  • Fork 3 You must be signed in to fork a gist
  • Save obstschale/b9bde4c6abd15687043d0504c41fb350 to your computer and use it in GitHub Desktop.
Save obstschale/b9bde4c6abd15687043d0504c41fb350 to your computer and use it in GitHub Desktop.
Raspberry Pi Script to autostart Chromium
# /home/pi/.config/lxsession/LXDE-pi/autostart before Buster
# /etc/xdg/lxsession/LXDE-pi/autostart on Buster
@lxpanel --profile LXDE-pi
@pcmanfm --desktop --profile LXDE-pi
@xscreensaver -no-splash
@point-rpi
@sh /home/pi/bin/start-chromium.sh
0 22 * * 1-5 shutdown > /dev/null 2>&1 # Shutdown at 22.00 on weekdays
0 23 * * 0,6 shutdown > /dev/null 2>&1 # Shutdown at 23.00 on weekends
# /home/pi/bin/start-chromium.sh
#!/bin/sh
set -e
CHROMIUM_TEMP=~/tmp/chromium
rm -Rf ~/.config/chromium/
rm -Rf $CHROMIUM_TEMP
mkdir -p $CHROMIUM_TEMP
chromium-browser \
--disable \
--disable-translate \
--disable-infobars \
--disable-suggestions-service \
--disable-save-password-bubble \
--disk-cache-dir=$CHROMIUM_TEMP/cache/ \
--user-data-dir=$CHROMIUM_TEMP/user_data/ \
--start-maximized \
--kiosk https://user:password@example.com &
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment