add rustdesk

This commit is contained in:
2025-04-06 12:01:32 -05:00
parent b38624a74c
commit 95a1f0f561
4 changed files with 70 additions and 0 deletions

View File

@@ -0,0 +1,56 @@
{ config, lib, ... }: {
options.sysconfig.opts.virtualization.rustdesk.enable = lib.options.mkOption {
type = lib.types.bool;
default = false;
};
config = lib.mkIf config.sysconfig.opts.virtualization.rustdesk.enable {
firewall.allowedTCPPorts = [ 21115 21116 21117 ];
firewall.allowedUDPPorts = [ 21116 ];
containers.rustdesk = {
autoStart = true;
privateNetwork = true;
hostAddress = "192.168.100.10";
localAddress = "192.168.100.21";
forwardPorts = [
{
containerPort = 21115;
hostPort = 21115;
}
{
containerPort = 21116;
hostPort = 21116;
}
{
containerPort = 21117;
hostPort = 21117;
}
];
config = {
services.rustdesk-server = {
enable = true;
openFirewall = true;
relay = {
enable = true;
#extraArgs = [ "" ];
};
signal = {
enable = true;
relayHosts = [ "rustdesk.blunkall.us:21117" ];
};
};
};
system.stateVersion = "24.05";
};
};
}