diff --git a/modules/default.nix b/modules/default.nix index d7ab66a..6b08ab0 100644 --- a/modules/default.nix +++ b/modules/default.nix @@ -1,5 +1,13 @@ -{ - desktop-sway = import ./desktop/sway.nix; - neovim = ./neovim; - zsh = ./zsh.nix; +let + sway = import ./desktop/sway.nix; +in { + home = { + sway = sway.home; + neovim = ./neovim; + zsh = ./zsh.nix; + ssh = ./ssh.nix; + }; + global = { + sway = sway.global; + }; } diff --git a/modules/ssh.nix b/modules/ssh.nix new file mode 100644 index 0000000..90c6be3 --- /dev/null +++ b/modules/ssh.nix @@ -0,0 +1,38 @@ +{ + programs.ssh = { + enable = true; + compression = true; + serverAliveCountMax = 1; + serverAliveInterval = 10; + matchBlocks = { + "*" = { + setEnv."TERM" = "xterm-256color"; + }; + + "watcher.kat" = { + user = "ubuntu"; + hostname = "watcher.katvayor.net"; + }; + "r86s.kat" = { + user = "root"; + hostname = "129.199.156.112"; + proxyJump = "sas.ens"; + }; + + "sas.ens" = { + user = "lbailly"; + hostname = "sas.eleves.ens.fr"; + }; + "degette.ens" = { + user = "dg"; + hostname = "www.dg.ens.fr"; + proxyJump = "sas.ens"; + }; + "bocal.ens" = { + user = "bocal"; + hostname = "fregate"; + proxyJump = "sas.ens"; + }; + }; + }; +} diff --git a/users/catvayor.nix b/users/catvayor.nix index 84837e3..8e2bb74 100644 --- a/users/catvayor.nix +++ b/users/catvayor.nix @@ -1,6 +1,6 @@ { config, pkgs, lib, mods, ... }: { - imports = [ mods.desktop-sway.global ]; + imports = with mods.global; [ sway ]; users.users.catvayor = { shell = pkgs.zsh; isNormalUser = true; @@ -22,7 +22,7 @@ home-manager.users.catvayor = { home.stateVersion = "23.11"; - imports = [ mods.neovim mods.zsh mods.desktop-sway.home ]; + imports = with mods.home; [ neovim zsh sway ssh ]; home.packages = with pkgs; [ wl-clipboard diff --git a/users/root.nix b/users/root.nix index 29960bf..264bd90 100644 --- a/users/root.nix +++ b/users/root.nix @@ -3,6 +3,6 @@ users.users.root.shell = pkgs.zsh; home-manager.users.root = { home.stateVersion = "23.11"; - imports = [ mods.neovim mods.zsh ]; + imports = with mods.home; [ neovim zsh ]; }; }