hotdog: add nginx config for acme in container
This commit is contained in:
parent
d165a0871c
commit
25d035de77
@ -4,6 +4,7 @@
|
|||||||
imports = [
|
imports = [
|
||||||
../../../krebs
|
../../../krebs
|
||||||
../../../krebs/2configs
|
../../../krebs/2configs
|
||||||
|
../../../krebs/2configs/nginx.nix
|
||||||
|
|
||||||
../../../krebs/2configs/buildbot-stockholm.nix
|
../../../krebs/2configs/buildbot-stockholm.nix
|
||||||
../../../krebs/2configs/binary-cache/nixos.nix
|
../../../krebs/2configs/binary-cache/nixos.nix
|
||||||
|
24
krebs/2configs/nginx.nix
Normal file
24
krebs/2configs/nginx.nix
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
{
|
||||||
|
networking.firewall.allowedTCPPorts = [ 80 443 ];
|
||||||
|
security.acme.acceptTerms = true;
|
||||||
|
security.acme.defaults.email = "spam@krebsco.de";
|
||||||
|
|
||||||
|
services.nginx = {
|
||||||
|
enable = true;
|
||||||
|
recommendedGzipSettings = true;
|
||||||
|
recommendedOptimisation = true;
|
||||||
|
recommendedTlsSettings = true;
|
||||||
|
|
||||||
|
enableReload = true;
|
||||||
|
|
||||||
|
virtualHosts.default = {
|
||||||
|
default = true;
|
||||||
|
locations."= /etc/os-release".extraConfig = ''
|
||||||
|
default_type text/plain;
|
||||||
|
alias /etc/os-release;
|
||||||
|
'';
|
||||||
|
# needed for acmeFallback in sync-containers, or other machines not reachable globally
|
||||||
|
locations."~ ^/.well-known/acme-challenge/".root = "/var/lib/acme/acme-challenge";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user