summaryrefslogtreecommitdiff
path: root/services/acme_server.nix
diff options
context:
space:
mode:
authorJohn Bargman2026-02-21 23:36:19 +0000
committerJohn Bargman2026-02-21 23:36:19 +0000
commite72a6620e2a38480d03cdb893879520feccaad7b (patch)
treedfd9553c152bbc431a2b60bde080326f4ffd6914 /services/acme_server.nix
parent474115c2c6d2ce965f45a60ca59490e128124878 (diff)
downloadcrash-web-e72a6620e2a38480d03cdb893879520feccaad7b.tar
crash-web-e72a6620e2a38480d03cdb893879520feccaad7b.tar.gz
crash-web-e72a6620e2a38480d03cdb893879520feccaad7b.tar.bz2
crash-web-e72a6620e2a38480d03cdb893879520feccaad7b.tar.lz
crash-web-e72a6620e2a38480d03cdb893879520feccaad7b.tar.xz
crash-web-e72a6620e2a38480d03cdb893879520feccaad7b.tar.zst
crash-web-e72a6620e2a38480d03cdb893879520feccaad7b.zip
fixup
Diffstat (limited to 'services/acme_server.nix')
-rw-r--r--services/acme_server.nix23
1 files changed, 23 insertions, 0 deletions
diff --git a/services/acme_server.nix b/services/acme_server.nix
new file mode 100644
index 0000000..bd6961b
--- /dev/null
+++ b/services/acme_server.nix
@@ -0,0 +1,23 @@
+{ fqdn }: { pkgs, config, lib, ... }:
+let
+ inherit fqdn;
+in
+{
+ users.groups.acme = { };
+
+ /* trigger the actual certificate generation for additional hostname */
+ security.acme.certs."${fqdn}" = {
+ extraDomainNames = [ "mail.crashoverburn.com"];
+ };
+
+ secrix.system.secrets.dns01.encrypted.file = ../secrets/gandi_dns01_token;
+ # Configure ACME appropriately
+ security.acme.acceptTerms = true;
+ security.acme.defaults = {
+ dnsProvider = "gandiv5";
+ group = "acme";
+ environmentFile = config.secrix.system.secrets.dns01.decrypted.path;
+ # We don't need to wait for propagation since this is a local DNS server
+ dnsPropagationCheck = false;
+ };
+}