Skip to content

Instantly share code, notes, and snippets.

@flixtor
Created October 9, 2022 11:26
Show Gist options
  • Select an option

  • Save flixtor/aa096a0065d140dd9531a050638f32d5 to your computer and use it in GitHub Desktop.

Select an option

Save flixtor/aa096a0065d140dd9531a050638f32d5 to your computer and use it in GitHub Desktop.
EndeavourOS & Arch linux VNC server setup
# This install needed tigervnc
sudo pacman -S tigervnc
# Password must be 6 char at minimum
vncpasswd
# Look in the vncserver.userfile on how to add new user, pretty simple.
sudo nano /etc/tigervnc/vncserver.users
# If 'sudo cat' is not working, just write 'sudo nano' instead and copy/paste the rest into the file.
# When it write EOF on your prompt, just hit 'enter' and go to next step
sudo cat <<EOF > ~/.vnc/config
session=$XDG_SESSION_DESKTOP
geometry=1920x1200
localhost=no
alwaysshared
EOF
# Enable your vncserver
sudo systemctl enable --now vncserver@:1.service
# Config our x0vncserver
sudo nano /etc/systemd/system/x0vncserver.service
[Unit]
Description=Remote desktop service (VNC)
After=syslog.target network.target
[Service]
Type=forking
User=$USER
ExecStart=/usr/bin/sh -c '/usr/bin/x0vncserver -display :0 -rfbport 15900 -passwordfile $HOME/.vnc/passwd &'
[Install]
WantedBy=multi-user.target
## - Exit and save file, your good to go.
## - All above it forked from: https://gist.github.com/miguelmota/9cd15049843ddf1ee1a52196f5c7e5ea
# I have only make some minor change, since I could not get all 'sudo cat' to work, so I used "sudo nano" instead.
@val-byte
Copy link
Copy Markdown

val-byte commented Dec 7, 2022

thanks i will try this

@dnslin
Copy link
Copy Markdown

dnslin commented Apr 27, 2025

Thanks. This is very useful to me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment