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

Add nm-networks per machine

This commit is contained in:
Stefan Ellmauthaler 2022-10-14 10:30:52 +02:00
parent e4f49d909d
commit 838a55807f
Signed by: ellmau
GPG Key ID: C804A9C1B7AF8256
3 changed files with 19 additions and 5 deletions

View File

@ -35,6 +35,10 @@
# add TUD vpn # add TUD vpn
openvpn.enable = true; openvpn.enable = true;
# nm-networks
networking.nmConnections = [
];
# enable sops # enable sops
sops = { sops = {
enable = true; enable = true;

View File

@ -37,6 +37,12 @@
# add TUD vpn # add TUD vpn
openvpn.enable = true; openvpn.enable = true;
# nm-networks
networking.nmConnections = [
"tartaros"
"eduroam"
];
# enable sops # enable sops
sops = { sops = {
enable = true; enable = true;

View File

@ -5,14 +5,18 @@
... ...
}: }:
with lib; { with lib; {
options.elss.networking.useNetworkManager = mkEnableOption "enable networkmanager"; options.elss.networking = {
useNetworkManager = mkEnableOption "enable networkmanager";
nmConnections = mkOption {
type = types.listOf types.str;
description = "Connections to instantiate for the machine";
default = [];
};
};
config = let config = let
hostName = config.system.name; hostName = config.system.name;
connections = [ connections = config.elss.networking.nmConnections;
"tartaros"
"eduroam"
];
mkSopsSecrets = connection: { mkSopsSecrets = connection: {
"${connection}" = { "${connection}" = {