Add on-demand Xvfb + x11vnc socket activation
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
[Unit]
|
||||
Description=X Virtual Framebuffer (On-Demand)
|
||||
After=network.target
|
||||
Documentation=https://www.x.org/wiki/
|
||||
|
||||
# Socket activation: starts only when x11vnc tries to connect
|
||||
Requires=xvfb.socket
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=intense
|
||||
Environment="DISPLAY=:99"
|
||||
ExecStart=/usr/bin/Xvfb :99 -screen 0 1920x1080x24 -listen tcp
|
||||
|
||||
# Restart on failure
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
|
||||
# Resource limits
|
||||
MemoryLimit=512M
|
||||
CPUQuota=50%
|
||||
|
||||
# Logging
|
||||
StandardOutput=journal
|
||||
StandardError=journal
|
||||
SyslogIdentifier=xvfb
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
Reference in New Issue
Block a user