nixos: gen 67 @ lilac — 2026-09-22 15:39 26.05.20260918.cf9d2fb (Yarara) ----- IP over bluetooth for seamless LAN-Mouse

This commit is contained in:
2026-09-22 15:39:56 -06:00
parent f99928c954
commit b1b6a6c395
3 changed files with 69 additions and 6 deletions
+32 -2
View File
@@ -25,12 +25,42 @@
boot.kernelModules = [ "thunderbolt-net" ];
networking.interfaces.thunderbolt0.ipv4.addresses = [{
networking.interfaces.bnep0.ipv4.addresses = [{
address = "10.0.0.2";
prefixLength = 24;
}];
networking.firewall.interfaces."thunderbolt0".allowedUDPPorts = [ 4242 ];
networking.firewall.interfaces."bnep0".allowedUDPPorts = [ 4242 ];
systemd = {
services = {
# 1. Start the listening server profile
bt-pan-server = {
description = "Bluetooth PAN GN Server";
after = [ "bluetooth.service" ];
wantedBy = [ "multi-user.target" ];
serviceConfig = {
ExecStart = "${pkgs.bluez-tools}/bin/bt-network -s gn pan0";
Restart = "always";
RestartSec = 5;
};
};
# 2. Trust and persistently attempt connection to Device A
bt-pan-client = {
description = "Bluetooth PAN Client Connection to Device A";
after = [ "bluetooth.service" "bt-pan-server.service" ];
wantedBy = [ "multi-user.target" ];
serviceConfig = {
# Replace XX:XX:XX:XX:XX:XX with Device B's actual Bluetooth MAC Address
ExecStartPre = "${pkgs.bluez}/bin/bluetoothctl trust 84:D1:C1:A9:EE:52";
ExecStart = "${pkgs.bluez-tools}/bin/bt-network -c 84:D1:C1:A9:EE:52 gn";
Restart = "always";
RestartSec = 10; # Retry every 10 seconds if Device B goes out of range
};
};
};
};
services.tlp = {
enable = false;