From 0875a66c70ab9a94de85a2104b0d47e8a3dd5e9e Mon Sep 17 00:00:00 2001 From: Sebastian Moser Date: Mon, 8 Apr 2024 18:21:13 +0200 Subject: [PATCH] added share nm-connection to main and lush --- hosts/lush.nix | 29 +++++++++++++++++++++++++++-- hosts/main.nix | 26 +++++++++++++++++++++++++- 2 files changed, 52 insertions(+), 3 deletions(-) diff --git a/hosts/lush.nix b/hosts/lush.nix index 69e731e..981ae13 100644 --- a/hosts/lush.nix +++ b/hosts/lush.nix @@ -110,14 +110,16 @@ networking.networkmanager.enable = true; networking.networkmanager.profiles = { - main = { + home = { connection = { id = "main"; uuid = "a02273d9-ad12-395e-8372-f61129635b6f"; type = "ethernet"; autoconnect-priority = "-999"; interface-name = "eth0"; + autoconnect = true; }; + ipv4 = { address1 = "192.168.1.44/24,192.168.1.1"; dns = "1.1.1.1;"; @@ -150,13 +152,36 @@ }; }; + share = { + connection = { + id = "share"; + uuid = "f55f34e3-4595-4642-b1f6-df3185bc0a04"; + type = "ethernet"; + autoconnect = false; + interface-name = "eth0"; + }; + + ethernet = { + mac-address = "F4:39:09:4A:DF:0E"; + }; + + ipv4 = { + address1 = "192.168.4.1/24"; + method = "shared"; + }; + + ipv6 = { + addr-gen-mode = "stable-privacy"; + method = "auto"; + }; + }; pt = { connection = { id = "pt"; uuid = "f028117e-9eef-47c1-8483-574f7ee798a4"; type = "bluetooth"; - autoconnect = "true"; + autoconnect = true; }; bluetooth = { diff --git a/hosts/main.nix b/hosts/main.nix index b26f08c..e94d936 100644 --- a/hosts/main.nix +++ b/hosts/main.nix @@ -318,7 +318,7 @@ id = "hot"; uuid = "ab51de8a-9742-465a-928b-be54a83ab6a3"; type = "wifi"; - autoconnect = "false"; + autoconnect = false; interface-name = "wlp2s0"; }; wifi = { @@ -332,6 +332,30 @@ }; }; + share = { + connection = { + id = "share"; + uuid = "f55f34e3-4595-4642-b1f6-df3185bc0a04"; + type = "ethernet"; + autoconnect = false; + interface-name = "enp1s0"; + }; + + ethernet = { + mac-address = "F4:39:09:4A:DF:0E"; + }; + + ipv4 = { + address1 = "192.168.4.1/24"; + method = "shared"; + }; + + ipv6 = { + addr-gen-mode = "stable-privacy"; + method = "auto"; + }; + }; + dhcp = { connection = { id = "dhcp";