diff options
| author | Gregor Kleen <gkleen@yggdrasil.li> | 2026-09-28 10:12:04 +0200 |
|---|---|---|
| committer | Gregor Kleen <gkleen@yggdrasil.li> | 2026-09-28 10:12:04 +0200 |
| commit | 0fbdb0cd87a55ac26df54694386953281850d0a9 (patch) | |
| tree | 53af1e57ef4ca14c17f55fb739889befdb15cb7c /accounts/gkleen@skadhi | |
| parent | 5996d5f84899fb919c6701f8acd599c5c23988e0 (diff) | |
| download | nixos-0fbdb0cd87a55ac26df54694386953281850d0a9.tar nixos-0fbdb0cd87a55ac26df54694386953281850d0a9.tar.gz nixos-0fbdb0cd87a55ac26df54694386953281850d0a9.tar.bz2 nixos-0fbdb0cd87a55ac26df54694386953281850d0a9.tar.xz nixos-0fbdb0cd87a55ac26df54694386953281850d0a9.zip | |
...
Diffstat (limited to 'accounts/gkleen@skadhi')
| -rw-r--r-- | accounts/gkleen@skadhi/default.nix | 2 | ||||
| -rw-r--r-- | accounts/gkleen@skadhi/rzm/default.nix | 41 |
2 files changed, 41 insertions, 2 deletions
diff --git a/accounts/gkleen@skadhi/default.nix b/accounts/gkleen@skadhi/default.nix index e4b35a78..1d6381a5 100644 --- a/accounts/gkleen@skadhi/default.nix +++ b/accounts/gkleen@skadhi/default.nix | |||
| @@ -288,6 +288,8 @@ in { | |||
| 288 | }; | 288 | }; |
| 289 | 289 | ||
| 290 | programs.chromium.enable = true; | 290 | programs.chromium.enable = true; |
| 291 | |||
| 292 | services.autosshProxy.vidhar.port = 8121; | ||
| 291 | }; | 293 | }; |
| 292 | }; | 294 | }; |
| 293 | } | 295 | } |
diff --git a/accounts/gkleen@skadhi/rzm/default.nix b/accounts/gkleen@skadhi/rzm/default.nix index 11d8af8b..e2a47362 100644 --- a/accounts/gkleen@skadhi/rzm/default.nix +++ b/accounts/gkleen@skadhi/rzm/default.nix | |||
| @@ -97,7 +97,7 @@ in { | |||
| 97 | ''; | 97 | ''; |
| 98 | }; | 98 | }; |
| 99 | 99 | ||
| 100 | home-manager.users.gkleen = { sysConfig, config, ... }: { | 100 | home-manager.users.gkleen = { sysConfig, config, lib, ... }: { |
| 101 | home.persistence."/persistent" = { | 101 | home.persistence."/persistent" = { |
| 102 | files = [ | 102 | files = [ |
| 103 | "rz.kdbx" | 103 | "rz.kdbx" |
| @@ -176,7 +176,36 @@ in { | |||
| 176 | pro = "$HOME/projects/pro"; | 176 | pro = "$HOME/projects/pro"; |
| 177 | }; | 177 | }; |
| 178 | 178 | ||
| 179 | programs.ssh.matchBlocks = { | 179 | programs.ssh.matchBlocks = let |
| 180 | autosshProxy = host: "${lib.getExe pkgs.socat} - SOCKS4A:127.0.0.1:%h:%p,socksport=${toString config.services.autosshProxy.${host}.port}"; | ||
| 181 | in { | ||
| 182 | "repo-apt01" = lib.hm.dag.entryBefore ["*.mathinst.loc"] { | ||
| 183 | user = "root"; | ||
| 184 | hostname = "repo-apt01.mathinst.loc"; | ||
| 185 | proxyCommand = autosshProxy "mgmt01"; | ||
| 186 | }; | ||
| 187 | "mgmt01" = lib.hm.dag.entryBefore ["*.mathinst.loc"] { | ||
| 188 | user = "root"; | ||
| 189 | hostname = "mgmt01.mathinst.loc"; | ||
| 190 | proxyCommand = autosshProxy "mathw0h"; | ||
| 191 | }; | ||
| 192 | "mathw0e" = lib.hm.dag.entryBefore ["*.mathinst.loc"] { | ||
| 193 | hostname = "mathw0e.mathinst.loc"; | ||
| 194 | proxyCommand = autosshProxy "mathw0h"; | ||
| 195 | }; | ||
| 196 | "cip04" = lib.hm.dag.entryBefore ["*.mathinst.loc"] { | ||
| 197 | hostname = "cip04.cipmath.loc"; | ||
| 198 | proxyCommand = autosshProxy "mathw0h"; | ||
| 199 | }; | ||
| 200 | "mathw0h" = lib.hm.dag.entryBefore ["*.mathinst.loc"] { | ||
| 201 | hostname = "mathw0h.mathinst.loc"; | ||
| 202 | proxyCommand = autosshProxy "ssh.math.lmu.de"; | ||
| 203 | }; | ||
| 204 | "math05" = lib.hm.dag.entryBefore ["*.mathinst.loc"] { | ||
| 205 | hostname = "math05.mathinst.loc"; | ||
| 206 | proxyCommand = autosshProxy "mathw0h"; | ||
| 207 | extraOptions.KexAlgorithms = "+diffie-hellman-group1-sha1"; | ||
| 208 | }; | ||
| 180 | "*.mathinst.loc" = { | 209 | "*.mathinst.loc" = { |
| 181 | match = "host *.mathinst.loc,*.cipmath.loc,*.math.lmu.de"; | 210 | match = "host *.mathinst.loc,*.cipmath.loc,*.math.lmu.de"; |
| 182 | identityFile = "~/.ssh/gkleen@mathinst.loc"; | 211 | identityFile = "~/.ssh/gkleen@mathinst.loc"; |
| @@ -191,6 +220,14 @@ in { | |||
| 191 | }; | 220 | }; |
| 192 | }; | 221 | }; |
| 193 | 222 | ||
| 223 | services.autosshProxy = { | ||
| 224 | "mgmt01" = { port = 8129; sshpassSecret = "root@mgmt01.mathinst.loc"; }; | ||
| 225 | "mathw0e" = { port = 8125; sshpassSecret = "gkleen@mathw0e.mathinst.loc"; }; | ||
| 226 | "mathw0h" = { port = 8123; sshpassSecret = "gkleen@mathw0h.mathinst.loc"; }; | ||
| 227 | "cip04" = { port = 8127; sshpassSecret = "gkleen@cip04.cipmath.loc"; }; | ||
| 228 | "ssh.math.lmu.de" = { port = 8119; sshpassSecret = "gkleen@ssh.math.lmu.de"; }; | ||
| 229 | }; | ||
| 230 | |||
| 194 | home.file = { | 231 | home.file = { |
| 195 | ".cups/client.conf".text = '' | 232 | ".cups/client.conf".text = '' |
| 196 | ServerName cups.mathinst.loc | 233 | ServerName cups.mathinst.loc |
