chore: put acme configuration in own file
This commit is contained in:
parent
7d21dcd59d
commit
65e8baabba
3 changed files with 17 additions and 13 deletions
16
acme.nix
Normal file
16
acme.nix
Normal file
|
|
@ -0,0 +1,16 @@
|
||||||
|
{ base-domain, ... }:
|
||||||
|
{
|
||||||
|
security.acme = {
|
||||||
|
certs.${base-domain}.extraDomainNames = [
|
||||||
|
"${base-domain}"
|
||||||
|
"sourcehut.${base-domain}"
|
||||||
|
"meta.sourcehut.${base-domain}"
|
||||||
|
"git.sourcehut.${base-domain}"
|
||||||
|
];
|
||||||
|
acceptTerms = true;
|
||||||
|
defaults = {
|
||||||
|
email = "khais.colin+letsencrypt@gmail.com";
|
||||||
|
dnsProvider = "namecheap";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
@ -3,6 +3,7 @@
|
||||||
imports = [
|
imports = [
|
||||||
./hardware-configuration.nix
|
./hardware-configuration.nix
|
||||||
./firewall.nix
|
./firewall.nix
|
||||||
|
(import ./acme.nix { base-domain = "005540.xyz"; })
|
||||||
./userprogs.nix
|
./userprogs.nix
|
||||||
./sourcehut.nix
|
./sourcehut.nix
|
||||||
];
|
];
|
||||||
|
|
|
||||||
|
|
@ -43,19 +43,6 @@ in
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
security.acme = {
|
|
||||||
certs.${base-domain}.extraDomainNames = [
|
|
||||||
"${fqdn}"
|
|
||||||
"meta.${fqdn}"
|
|
||||||
"git.${fqdn}"
|
|
||||||
];
|
|
||||||
acceptTerms = true;
|
|
||||||
defaults = {
|
|
||||||
email = "khais.colin+letsencrypt@gmail.com";
|
|
||||||
dnsProvider = "namecheap";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
services.nginx = {
|
services.nginx = {
|
||||||
enable = true;
|
enable = true;
|
||||||
recommendedTlsSettings = true;
|
recommendedTlsSettings = true;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue