Installing Rust Desk
Rust Desk is an open source remote desktop program that consists of a client and a server. If you want you can just use the client and then use the official servers to remote between desktops but this is the very easy install I use on Open Media Vault 7 (OMV 7) to remote around the machines in the house. And, since OMV 7 is based on Debian 12 this guide should work for anyone using Debian or its derivatives such as Ubuntu.
You will need ssh access to your server and permissions to install software.
Firewall
Firstly open up your firewall ports. If you are using ufw as a firewall then this should open the ports for you,
ufw allow 21114:21119/tcp
ufw allow 21116/udp
sudo ufw enable
However on OMV 7 things are a little slower and it is easiest to go to the Network/Firewall/Rules tab on the GUI and enter the rules there for both input and output. It's a good idea to place a note saying what program it is for as well.
Mine looks a little like this,
Direction | Action | Source | Port | Destination | Port | Protocol | Tags |
INPUT | ACCEPT | 10.0.0.0/24 | 21114-21119 | 10.0.0.200 | 21114-21119 | TCP | Rust Desk |
OUTPUT | ACCEPT | 10.0.0.200 | 21114-21119 | 10.0.0.0/24 | 21114-21119 | TCP | Rust Desk |
INPUT | ACCEPT | 10.0.0.0/24 | 21116 | 10.0.0.200 | 21116 | UDP | Rust Desk |
OUTPUT | ACCEPT | 10.0.0.200 | 21116 | 10.0.0.0/24 | 21116 | UDP | Rust Desk |
Note: There are also instructions for opening up port 8000 for the web interface but that is not needed.
Install the programs
There are two programs you need to install, the hbbr and the hbbs. You can find them here. Next ssh into your server and use wget to down load both the files for the correct architecture. For instance my server is using a 64bit x86 CPU so my architecture is and64.
The wget command will look something like this and will download the files into the folder you are in.
wget https://github.com/rustdesk/rustdesk-server/releases/download/1.1.12/rustdesk-server-hbbr_1.1.12_amd64.deb
dpkg -i rustdesk-server-hbbr_1.1.12_amd64.deb
Find the public key
Probably the hardest and most confusing step for me is finding the public key that you need to enter into your Rust Desk clients to allow them to connect to the server. This key is created by hbbs when it is started and it detects there is no existing key.
The directory you want is,
/var/lib/rustdesk-server/
And the file will be called something like id_ed25519.pub. The important part is that it ends with pub (for public key). Show the key using cat,
cat /var/lib/rustdesk-server/id_ed25519.pub
And copy that key. You are going to need to use it on every machine. If you haven't installed the client on your desktop already then do so. You can get the client from here. Having installed and started it you need to go to the Settings/Network/ID Relay server tab and enter the information for your server there.
Mine looks a little like,
ID Relay server | |
ID server: | 10.0.0.200 |
Relay server: | 10.0.0.200 |
API server: | https://10.0.0.200 |
Key | zd,kfvhgzslkduhawejkfnskdvh;sjk= |
And that is it. You should be connected. At the top of your ID Relay server tab you can now copy a one line code for all that information and then paste it into the other desktop clients to save you having to enter all the information constantly.