Open gabrielSant95 opened 10 hours ago
apt-get update
apt-get install \
unclutter \
xorg \
chromium \
openbox \
lightdm \
locales \
-y
mkdir -p /home/kiosk/.config/openbox
groupadd kiosk
id -u kiosk &>/dev/null || useradd -m kiosk -g kiosk -s /bin/bash
chown -R kiosk:kiosk /home/kiosk
if [ -e "/etc/X11/xorg.conf" ]; then
mv /etc/X11/xorg.conf /etc/X11/xorg.conf.backup
fi
cat > /etc/X11/xorg.conf << EOF
Section "ServerFlags"
Option "DontVTSwitch" "true"
EndSection
EOF
if [ -e "/etc/lightdm/lightdm.conf" ]; then
mv /etc/lightdm/lightdm.conf /etc/lightdm/lightdm.conf.backup
fi
cat > /etc/lightdm/lightdm.conf << EOF
[SeatDefaults]
autologin-user=kiosk
user-session=openbox
EOF
if [ -e "/home/kiosk/.config/openbox/autostart" ]; then
mv /home/kiosk/.config/openbox/autostart /home/kiosk/.config/openbox/autostart.backup
fi
cat > /home/kiosk/.config/openbox/autostart << EOF
unclutter -idle 0.1 -grab -root &
while :
do
xrandr --auto
chromium \
--no-first-run \
--start-maximized \
--disable \
--disable-translate \
--disable-infobars \
--autoplay-policy=no-user-gesture-required \
--disable-features=translate \
--ignore-certificate-errors \
--disable-web-security \
--remember-cert-error-decisions \
--start-maximized \
--disable-suggestions-service \
--disable-save-password-bubble \
--disable-session-crashed-bubble \
--incognito \
--kiosk "https://YOU_URL"
--start-maximized \
--kiosk "https://YOU_URL/"
sleep 5
done &
EOF
echo "Done!"
transform you linux mint into kiosk mode