diff --git a/modules/nixos/common/deployrs.nix b/modules/nixos/common/deployrs.nix index 61a6c68..0caf926 100644 --- a/modules/nixos/common/deployrs.nix +++ b/modules/nixos/common/deployrs.nix @@ -1,4 +1,7 @@ { lib, config, ... }: +let + hosts = builtins.fromJSON (builtins.readFile ../../../container_ips.json); +in { options.deploy = { enable = lib.mkEnableOption "enable deployrs module" // { @@ -6,7 +9,7 @@ }; address = lib.mkOption { type = lib.types.str; - default = config.networking.hostName; + default = hosts.${config.networking.hostName}; }; }; }