Skip to content

Instantly share code, notes, and snippets.

@theodric
Created January 31, 2025 13:10
Show Gist options
  • Save theodric/9dcbd37fa5789336bb60b343cadbcc42 to your computer and use it in GitHub Desktop.
Save theodric/9dcbd37fa5789336bb60b343cadbcc42 to your computer and use it in GitHub Desktop.
TightVNC systemd unit file for Debian
[Unit]
Description=Start TightVNC server at startup
After=syslog.target network.target
[Service]
Type=forking
User=someusername
Group=somegroupname
WorkingDirectory=/home/someusername
PIDFile=/home/someusername/.vnc/%H:%i.pid
ExecStartPre=-/usr/bin/vncserver -kill :%i > /dev/null 2>&1
#ExecStart=/usr/bin/vncserver -depth 24 -geometry 1800x1200 -nevershared :%i
ExecStart=/usr/bin/vncserver -depth 24 -geometry 2080x1386 -nevershared :%i
ExecStop=/usr/bin/vncserver -kill :%i
[Install]
WantedBy=multi-user.target
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment