2023-08-28 21:52:46 +02:00
|
|
|
{ options, config, lib, fn, pkgs, ... }:
|
2020-03-11 01:53:04 +01:00
|
|
|
|
|
|
|
with builtins;
|
|
|
|
with lib;
|
|
|
|
|
|
|
|
let
|
|
|
|
cfg = config.machine;
|
|
|
|
in mkIf (elem "acme" cfg.services) {
|
|
|
|
security.acme = {
|
|
|
|
# see https://letsencrypt.org/repository/
|
|
|
|
acceptTerms = true;
|
2023-09-10 15:24:35 +02:00
|
|
|
defaults.email = "${(elemAt cfg.mailAccounts 0).name}@${cfg.domain}";
|
2020-03-11 01:53:04 +01:00
|
|
|
};
|
|
|
|
}
|