fixed RDP layout
This commit is contained in:
1
app/icons/rdp.svg
Normal file
1
app/icons/rdp.svg
Normal file
@@ -0,0 +1 @@
|
|||||||
|
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64"><rect x="6" y="12" width="52" height="34" rx="4" fill="#3584E4" stroke="#fff" stroke-width="2"/><rect x="12" y="18" width="40" height="22" rx="2" fill="#1A1A2E"/><rect x="26" y="46" width="12" height="4" rx="1" fill="#aaa"/><rect x="20" y="50" width="24" height="3" rx="1.5" fill="#888"/></svg>
|
||||||
|
After Width: | Height: | Size: 354 B |
@@ -14,9 +14,11 @@ let
|
|||||||
{ label = "Root Password"; file = "/var/lib/secrets/root-password"; }
|
{ label = "Root Password"; file = "/var/lib/secrets/root-password"; }
|
||||||
{ label = "SSH Local Access"; value = "ssh root@localhost / Passphrase: gosovransystems"; }
|
{ label = "SSH Local Access"; value = "ssh root@localhost / Passphrase: gosovransystems"; }
|
||||||
]; }
|
]; }
|
||||||
|
{ name = "Remote Desktop"; unit = "gnome-remote-desktop.service"; type = "system"; icon = "rdp"; enabled = cfg.features.rdp; category = "infrastructure"; credentials = [
|
||||||
{ name = "Remote Desktop (RDP)"; unit = "gnome-remote-desktop.service"; type = "system"; icon = "rdp"; enabled = cfg.features.rdp; category = "apps"; credentials = [
|
{ label = "Username"; file = "/var/lib/gnome-remote-desktop/rdp-username"; }
|
||||||
{ label = "Credentials"; file = "/var/lib/gnome-remote-desktop/rdp-credentials"; multiline = true; }
|
{ label = "Password"; file = "/var/lib/gnome-remote-desktop/rdp-password"; }
|
||||||
|
{ label = "Address"; file = "/var/lib/secrets/internal-ip"; suffix = ":3389"; }
|
||||||
|
{ label = "How to Connect"; value = "1. Install an RDP client (e.g. Remmina, Microsoft Remote Desktop)\n2. Create a new RDP connection\n3. Enter the Address above as the host\n4. Enter the Username and Password above\n5. Connect — you will see your desktop remotely"; }
|
||||||
]; }
|
]; }
|
||||||
]
|
]
|
||||||
# ── Bitcoin Base (node implementations) ────────────────────
|
# ── Bitcoin Base (node implementations) ────────────────────
|
||||||
@@ -182,7 +184,7 @@ let
|
|||||||
# ── Generated config ───────────────────────────────────────
|
# ── Generated config ───────────────────────────────────────
|
||||||
cp ${generatedConfig} $out/lib/sovran-hub-web/config.json
|
cp ${generatedConfig} $out/lib/sovran-hub-web/config.json
|
||||||
|
|
||||||
# ── Icons (SVG) ────────────────────────────────────────────
|
# ── Icons (SVG) ──────────────────<EFBFBD><EFBFBD>─────────────────────────
|
||||||
install -d $out/share/sovran-hub/icons
|
install -d $out/share/sovran-hub/icons
|
||||||
cp icons/* $out/share/sovran-hub/icons/ 2>/dev/null || true
|
cp icons/* $out/share/sovran-hub/icons/ 2>/dev/null || true
|
||||||
|
|
||||||
|
|||||||
@@ -1,21 +1,16 @@
|
|||||||
{ config, pkgs, lib, ... }:
|
{ config, lib, pkgs, ... }:
|
||||||
|
|
||||||
lib.mkIf config.sovran_systemsOS.features.rdp {
|
lib.mkIf config.sovran_systemsOS.features.rdp {
|
||||||
|
|
||||||
services.gnome.gnome-remote-desktop.enable = true;
|
services.gnome-remote-desktop.enable = true;
|
||||||
|
|
||||||
networking.firewall.allowedTCPPorts = [ 3389 ];
|
users.users.gnome-remote-desktop = {
|
||||||
|
isSystemUser = true;
|
||||||
environment.systemPackages = with pkgs; [
|
group = "gnome-remote-desktop";
|
||||||
freerdp
|
home = "/var/lib/gnome-remote-desktop";
|
||||||
];
|
createHome = true;
|
||||||
|
|
||||||
# The NixOS module installs the unit but doesn't enable it — we just need to start it and order it
|
|
||||||
systemd.services.gnome-remote-desktop = {
|
|
||||||
wantedBy = [ "graphical.target" ];
|
|
||||||
after = [ "gnome-remote-desktop-setup.service" ];
|
|
||||||
wants = [ "gnome-remote-desktop-setup.service" ];
|
|
||||||
};
|
};
|
||||||
|
users.groups.gnome-remote-desktop = {};
|
||||||
|
|
||||||
systemd.tmpfiles.rules = [
|
systemd.tmpfiles.rules = [
|
||||||
"d /var/lib/gnome-remote-desktop 0750 gnome-remote-desktop gnome-remote-desktop -"
|
"d /var/lib/gnome-remote-desktop 0750 gnome-remote-desktop gnome-remote-desktop -"
|
||||||
@@ -77,6 +72,10 @@ lib.mkIf config.sovran_systemsOS.features.rdp {
|
|||||||
PASSWORD=$(cat /var/lib/gnome-remote-desktop/rdp-password)
|
PASSWORD=$(cat /var/lib/gnome-remote-desktop/rdp-password)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Write username to a separate file for the hub
|
||||||
|
echo "sovran" > /var/lib/gnome-remote-desktop/rdp-username
|
||||||
|
chmod 600 /var/lib/gnome-remote-desktop/rdp-username
|
||||||
|
|
||||||
# Get current IP address
|
# Get current IP address
|
||||||
LOCAL_IP=$(hostname -I | awk '{print $1}')
|
LOCAL_IP=$(hostname -I | awk '{print $1}')
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user