Benjamin Bädorf
6fc5b2553c
All checks were successful
continuous-integration/drone/push Build is passing
48 lines
968 B
Nix
48 lines
968 B
Nix
{
|
|
config,
|
|
pkgs,
|
|
lib,
|
|
self,
|
|
...
|
|
}:
|
|
with lib; let
|
|
psCfg = config.pub-solar;
|
|
xdg = config.home-manager.users."${psCfg.user.name}".xdg;
|
|
in {
|
|
age.secrets."cat-test.ovpn" = {
|
|
file = "${self}/secrets/cat-test.ovpn";
|
|
mode = "700";
|
|
owner = psCfg.user.name;
|
|
};
|
|
|
|
age.secrets.".fwknoprc" = {
|
|
file = "${self}/secrets/.fwknoprc";
|
|
path = "${config.users.users."${psCfg.user.name}".home}/.fwknoprc";
|
|
mode = "600";
|
|
owner = psCfg.user.name;
|
|
};
|
|
|
|
services.openvpn.servers = {
|
|
catVPN = {
|
|
config = ''config /run/agenix/cat-test.ovpn '';
|
|
};
|
|
};
|
|
|
|
home-manager = pkgs.lib.setAttrByPath ["users" psCfg.user.name] {
|
|
programs.ssh = {
|
|
matchBlocks = {
|
|
"salt.base.test" = {
|
|
hostname = "10.0.0.2";
|
|
user = "bbaedorf";
|
|
};
|
|
|
|
"salt.gateway.test" = {
|
|
hostname = "10.0.0.3";
|
|
user = "root";
|
|
proxyJump = "salt.base.test";
|
|
};
|
|
};
|
|
};
|
|
};
|
|
}
|