services: use wildcard certificate

Should have done this a long time ago
This commit is contained in:
Antoine Martin 2021-07-13 00:57:33 +02:00
parent 64d479e2ce
commit f0e5e90c10
14 changed files with 37 additions and 21 deletions

View file

@ -2,11 +2,12 @@
with lib;
let cfg = config.my.services.monitoring;
let
cfg = config.my.services.monitoring;
domain = config.networking.domain;
in {
options.my.services.monitoring = {
enable = mkEnableOption "Enable monitoring";
useACME = mkEnableOption "Get HTTPS certs";
domain = mkOption {
type = types.str;
@ -76,8 +77,8 @@ in {
proxyWebsockets = true;
};
forceSSL = cfg.useACME;
enableACME = cfg.useACME;
forceSSL = true;
useACMEHost = domain;
};
};
};