updated hosts in network.nix

This commit is contained in:
pagedmov
2024-11-02 17:14:19 -04:00
parent ce51067835
commit 2ca5f9351e
3 changed files with 12 additions and 2 deletions

View File

@@ -0,0 +1,6 @@
{ pkgs }:
pkgs.writeShellScriptBin "icanhazip" ''
echo "Public IP: $(curl -s icanhazip.com -4)"
ip route | awk '/default/ {print "Default Gateway: " $3} /src/ {print "Local IP: " $9}' | head -n 2
''

View File

@@ -11,6 +11,7 @@
splash = import ./commands/splash.nix { inherit self pkgs; };
runbg = import ./commands/runbg.nix { inherit self pkgs; };
mkbackup = import ./commands/mkbackup.nix { inherit pkgs; };
icanhazip = import ./commands/icanhazip.nix { inherit pkgs; };
garbage-collect = import ./nix/garbage-collect.nix { inherit self pkgs; };
nsp = import ./nix/nsp.nix { inherit self pkgs; };
scheck = import ./wm-controls/s_check.nix { inherit self pkgs; };
@@ -44,6 +45,8 @@ in {
# Individual options using scriptOverride or mkEnableOption directly
movScripts.commandScripts.mkbackup.enable =
scriptOverride "Enables the mkbackup command" "commandScripts" "mkbackup";
movScripts.commandScripts.icanhazip.enable =
scriptOverride "Enables the icanhazip command" "commandScripts" "icanhazip";
movScripts.commandScripts.invoke.enable =
scriptOverride "Enables the invoke command" "commandScripts" "invoke";
movScripts.commandScripts.runbg.enable =
@@ -80,6 +83,7 @@ in {
home.packages = lib.optionals config.movScripts.commandScripts.invoke.enable [ invoke ]
++ lib.optionals config.movScripts.commandScripts.runbg.enable [ runbg ]
++ lib.optionals config.movScripts.commandScripts.mkbackup.enable [ mkbackup ]
++ lib.optionals config.movScripts.commandScripts.icanhazip.enable [ icanhazip ]
++ lib.optionals config.movScripts.commandScripts.splash.enable [ splash ]
++ lib.optionals config.movScripts.commandScripts.toolbelt.enable [ toolbelt ]
++ lib.optionals config.movScripts.commandScripts.viconf.enable [ viconf ]

View File

@@ -8,8 +8,8 @@
networkmanager.enable = true;
hostName = "${host}";
hosts = {
"192.168.1.201" = ["xenon"];
"192.168.1.111" = ["argon"];
"192.168.1.200" = ["xenon"];
"192.168.1.201" = ["oganesson"];
"192.168.1.223" = ["mercury"];
};
firewall = {