forked from Drift/pvv-nixos-config
Compare commits
1 Commits
setup-kerb
...
setup-home
Author | SHA1 | Date | |
---|---|---|---|
ddc4d8cea0
|
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
../../base.nix
|
../../base.nix
|
||||||
../../misc/metrics-exporters.nix
|
../../misc/metrics-exporters.nix
|
||||||
../../modules/kerberos_auth.nix
|
../../modules/home-areas.nix
|
||||||
|
|
||||||
#./services/keycloak.nix
|
#./services/keycloak.nix
|
||||||
|
|
||||||
|
@@ -5,6 +5,7 @@
|
|||||||
|
|
||||||
../../base.nix
|
../../base.nix
|
||||||
../../misc/metrics-exporters.nix
|
../../misc/metrics-exporters.nix
|
||||||
|
../../modules/home-areas.nix
|
||||||
./services/nginx
|
./services/nginx
|
||||||
|
|
||||||
./acmeCert.nix
|
./acmeCert.nix
|
||||||
|
@@ -5,6 +5,7 @@
|
|||||||
./hardware-configuration.nix
|
./hardware-configuration.nix
|
||||||
../../base.nix
|
../../base.nix
|
||||||
../../misc/metrics-exporters.nix
|
../../misc/metrics-exporters.nix
|
||||||
|
../../modules/home-areas.nix
|
||||||
|
|
||||||
./services/openvpn-client.nix
|
./services/openvpn-client.nix
|
||||||
];
|
];
|
||||||
|
@@ -5,6 +5,7 @@
|
|||||||
./hardware-configuration.nix
|
./hardware-configuration.nix
|
||||||
../../base.nix
|
../../base.nix
|
||||||
../../misc/metrics-exporters.nix
|
../../misc/metrics-exporters.nix
|
||||||
|
../../modules/home-areas.nix
|
||||||
|
|
||||||
./services/nginx
|
./services/nginx
|
||||||
./services/metrics
|
./services/metrics
|
||||||
|
@@ -5,6 +5,7 @@
|
|||||||
./hardware-configuration.nix
|
./hardware-configuration.nix
|
||||||
../../base.nix
|
../../base.nix
|
||||||
../../misc/metrics-exporters.nix
|
../../misc/metrics-exporters.nix
|
||||||
|
../../modules/home-areas.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
sops.defaultSopsFile = ../../secrets/shark/shark.yaml;
|
sops.defaultSopsFile = ../../secrets/shark/shark.yaml;
|
||||||
|
27
modules/home-areas.nix
Normal file
27
modules/home-areas.nix
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
{ pkgs, lib, ... }:
|
||||||
|
{
|
||||||
|
fileSystems = let
|
||||||
|
shorthandAreas = {
|
||||||
|
# See toriel:/etc/exports
|
||||||
|
"/home/pvv/t/pederbs" = "homepvvt.pvv.ntnu.no:/export/home/pvv/t/pederbs";
|
||||||
|
"/home/pvv/t/yorinad" = "homepvvt.pvv.ntnu.no:/export/home/pvv/t/yorinad";
|
||||||
|
}
|
||||||
|
//
|
||||||
|
# See microbel:/etc/exports
|
||||||
|
(lib.listToAttrs (map
|
||||||
|
(l: lib.nameValuePair "/home/pvv/${l}" "homepvv${l}.pvv.ntnu.no:/export/home/pvv/${l}")
|
||||||
|
[ "a" "b" "c" "d" "h" "i" "j" "k" "l" "m" "z" ]));
|
||||||
|
in { }
|
||||||
|
//
|
||||||
|
(lib.mapAttrs (_: device: {
|
||||||
|
inherit device;
|
||||||
|
fsType = "nfs";
|
||||||
|
options = [
|
||||||
|
"nfsvers=3"
|
||||||
|
"noauto"
|
||||||
|
"proto=tcp"
|
||||||
|
"x-systemd.automount"
|
||||||
|
"x-systemd.idle-timeout=300"
|
||||||
|
];
|
||||||
|
}) shorthandAreas);
|
||||||
|
}
|
@@ -1,25 +0,0 @@
|
|||||||
{ pkgs, lib, ... }:
|
|
||||||
{
|
|
||||||
environment.systemPackages = with pkgs; [
|
|
||||||
heimdal
|
|
||||||
];
|
|
||||||
|
|
||||||
security.pam.krb5.enable = true;
|
|
||||||
|
|
||||||
environment.etc."krb5.conf".text = ''
|
|
||||||
[libdefaults]
|
|
||||||
default_realm = PVV.NTNU.NO
|
|
||||||
dns_lookup_realm = yes
|
|
||||||
dns_lookup_kdc = yes
|
|
||||||
|
|
||||||
[appdefaults]
|
|
||||||
pam = {
|
|
||||||
ignore_k5login = yes
|
|
||||||
}
|
|
||||||
|
|
||||||
[realms]
|
|
||||||
PVV.NTNU.NO = {
|
|
||||||
admin_server = kdc.pvv.ntnu.no
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
}
|
|
Reference in New Issue
Block a user