ssh: home network option for ssh
This commit is contained in:
parent
344f34c061
commit
02067516a8
1 changed files with 3 additions and 1 deletions
|
@ -6,6 +6,8 @@ in
|
||||||
{
|
{
|
||||||
options.snowhawk.ssh = {
|
options.snowhawk.ssh = {
|
||||||
enable = lib.mkEnableOption "ssh";
|
enable = lib.mkEnableOption "ssh";
|
||||||
|
|
||||||
|
homeNetwork = lib.mkEnableOption "include local hostnames for home network devices";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
|
@ -23,7 +25,7 @@ in
|
||||||
user = "zynh";
|
user = "zynh";
|
||||||
identityFile = "${config.home.homeDirectory}/.ssh/msiserver";
|
identityFile = "${config.home.homeDirectory}/.ssh/msiserver";
|
||||||
};
|
};
|
||||||
"msiserver.local" = {
|
"msiserver.local" = lib.mkIf cfg.homeNetwork {
|
||||||
hostname = "msiserver";
|
hostname = "msiserver";
|
||||||
user = "zynh";
|
user = "zynh";
|
||||||
identityFile = "${config.home.homeDirectory}/.ssh/msiserver";
|
identityFile = "${config.home.homeDirectory}/.ssh/msiserver";
|
||||||
|
|
Loading…
Reference in a new issue