1
0
mirror of https://github.com/ellmau/nixos.git synced 2025-12-19 09:29:36 +01:00

Use per-machine secrets for NetworkManager

This commit is contained in:
Stefan Ellmauthaler 2022-10-05 17:20:34 +02:00
parent 54a5ab226d
commit 845829b12e
Failed to extract signature
3 changed files with 2 additions and 1 deletions

View File

View File

@ -8,6 +8,7 @@ with lib; {
options.elss.networking.useNetworkManager = mkEnableOption "enable networkmanager";
config = let
hostName = config.system.name;
connections = [
"tartaros"
"eduroam"
@ -15,7 +16,7 @@ with lib; {
mkSopsSecrets = connection: {
"${connection}" = {
sopsFile = ../../secrets/networks.yaml;
sopsFile = ../../machines + builtins.toPath "/${hostName}/secrets/networks.yaml";
path = "/run/NetworkManager/system-connections/${connection}.nmconnection";
};
};