以 Debian Server 开机启动 Chromium 为例:
使用 Xorg
```bash
sudo apt install -y xorg chromium fonts-noto*
sudo dpkg-reconfigure locales
sudo dpkg-reconfigure tzdata
nano ~/.xinitrc
#!/bin/bash
# xrandr >/tmp/x.log
sx=1920
sy=1080
# 禁用 DPMS
xset -dpms
# 禁用屏幕保护程序
xset s off
# 禁止屏幕空白
xset s noblank
xrandr --output HDMI-1 --mode ${sx}x${sy} --pos 0x0
xsetroot -solid red && sleep 1
xsetroot -solid green && sleep 1
xsetroot -solid blue && sleep 1
xsetroot -solid black
# xsetroot -bitmap /boot/backgroud.xbm && sleep 1
# feh --bg-scale /home/pi/133.jpg && sleep 2
chromium-browser --kiosk --incognito \
--window-size=${sx},${sy} --window-position=0,0 \
--app=
https://www.baidu.comnano ~/.bashrc
if [[ -z $DISPLAY && $XDG_VTNR -eq 1 ]]; then
exec startx
fi
# 然后 systemd 设置一个用户自动登录 shell
```
使用 Wayland
```bash
sudo apt install -y weston chromium fonts-noto* wayland-utils
# man 5 weston.ini
nano ~/.config/weston.ini
[core]
#shell=
kiosk-shell.soidle-time=0
#xwayland=true
[shell]
background-image=/home/orangepi/background.jpg
background-type=scale-crop
clock-format=seconds-24h
#panel-position=none
locking=false
[output]
name=HDMI-A-1
mode=1024x600
#transform=rotate-90
#scale=2
#[xwayland]
#path=/usr/bin/Xwayland
[autolaunch]
path=/home/orangepi/
launch.shwatch=true
nano ~/
launch.sh#!/bin/bash
# weston-info >/tmp/w.log
wayland-info >/tmp/w.log
chromium --enable-features=UseOzonePlatform \
--ozone-platform=wayland \
--kiosk --incognito \
--window-size=1024,600 \
--window-position=0,0 \
--app=
https://www.baidu.com# 开机自启动
https://wayland.pages.freedesktop.org/weston/toc/running-weston.html#running-weston-from-a-systemd-service```