DRY security.acme
This commit is contained in:
parent
fe58dc6cdd
commit
dcfdd87899
|
@ -13,10 +13,6 @@
|
||||||
|
|
||||||
nixpkgs.config.allowUnfree = true;
|
nixpkgs.config.allowUnfree = true;
|
||||||
|
|
||||||
security.acme = {
|
|
||||||
email = "mail@c3d2.de";
|
|
||||||
acceptTerms = true;
|
|
||||||
};
|
|
||||||
security.pam.enableSSHAgentAuth = true;
|
security.pam.enableSSHAgentAuth = true;
|
||||||
|
|
||||||
services.openssh = {
|
services.openssh = {
|
||||||
|
|
|
@ -26,10 +26,6 @@
|
||||||
package = pkgs.kibana7;
|
package = pkgs.kibana7;
|
||||||
};
|
};
|
||||||
|
|
||||||
security.acme = {
|
|
||||||
acceptTerms = true;
|
|
||||||
email = "mail@c3d2.de";
|
|
||||||
};
|
|
||||||
services.nginx = let
|
services.nginx = let
|
||||||
authFile = pkgs.writeText "htpasswd" "k-ot:sawCOTsl/fIUY";
|
authFile = pkgs.writeText "htpasswd" "k-ot:sawCOTsl/fIUY";
|
||||||
vhost = url: {
|
vhost = url: {
|
||||||
|
|
|
@ -45,9 +45,4 @@
|
||||||
hostname = "matemat.hq.c3d2.de";
|
hostname = "matemat.hq.c3d2.de";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
security.acme = {
|
|
||||||
acceptTerms = true;
|
|
||||||
email = "mail@c3d2.de";
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -49,8 +49,4 @@
|
||||||
locations."/".proxyPass = "http://localhost:4000";
|
locations."/".proxyPass = "http://localhost:4000";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
security.acme = {
|
|
||||||
acceptTerms = true;
|
|
||||||
email = "mail@c3d2.de";
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -40,10 +40,6 @@ in {
|
||||||
root = config.users.users.scrape.home;
|
root = config.users.users.scrape.home;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
security.acme = {
|
|
||||||
acceptTerms = true;
|
|
||||||
email = "mail@c3d2.de";
|
|
||||||
};
|
|
||||||
networking.firewall.allowedTCPPorts = [ 80 443 ];
|
networking.firewall.allowedTCPPorts = [ 80 443 ];
|
||||||
|
|
||||||
systemd.services = let
|
systemd.services = let
|
||||||
|
|
|
@ -47,9 +47,4 @@ in
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
security.acme = {
|
|
||||||
acceptTerms = true;
|
|
||||||
email = "mail@c3d2.de";
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -135,11 +135,6 @@ in
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
security.acme = {
|
|
||||||
acceptTerms = true;
|
|
||||||
email = "mail@c3d2.de";
|
|
||||||
};
|
|
||||||
|
|
||||||
services.nginx = {
|
services.nginx = {
|
||||||
enable = true;
|
enable = true;
|
||||||
#recommendedGzipSettings = true;
|
#recommendedGzipSettings = true;
|
||||||
|
|
|
@ -149,10 +149,6 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
security.acme = {
|
|
||||||
acceptTerms = true;
|
|
||||||
email = "mail@c3d2.de";
|
|
||||||
};
|
|
||||||
|
|
||||||
# Allow access to USB
|
# Allow access to USB
|
||||||
services.udev.extraRules = ''
|
services.udev.extraRules = ''
|
||||||
|
|
|
@ -60,6 +60,14 @@ in {
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
acmeEmail = mkOption {
|
||||||
|
type = str;
|
||||||
|
default = "mail@c3d2.de";
|
||||||
|
description = ''
|
||||||
|
Admin email address to use for Letsencrypt
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
hq = {
|
hq = {
|
||||||
|
|
||||||
/* externalInterface = mkOption {
|
/* externalInterface = mkOption {
|
||||||
|
@ -258,6 +266,11 @@ in {
|
||||||
rebootTime = "15s";
|
rebootTime = "15s";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# Defaults for LetsEncrypt
|
||||||
|
security.acme = {
|
||||||
|
acceptTerms = true;
|
||||||
|
email = cfg.acmeEmail;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
meta.maintainers = with lib.maintainers; [ ehmry ];
|
meta.maintainers = with lib.maintainers; [ ehmry ];
|
||||||
|
|
Loading…
Reference in New Issue