2023-04-25 15:57:59 +02:00
|
|
|
{ pkgs, ... }:
|
|
|
|
{
|
|
|
|
security.acme = {
|
|
|
|
acceptTerms = true;
|
|
|
|
defaults = {
|
|
|
|
email = "jade@schrottkatze.de";
|
|
|
|
webroot = "/var/lib/acme/acme-challenge";
|
|
|
|
};
|
|
|
|
certs = {
|
2023-05-03 00:01:02 +02:00
|
|
|
"meet.katzen.cafe" = {
|
|
|
|
group = "nginx";
|
|
|
|
keyType = "rsa4096";
|
|
|
|
};
|
2023-04-30 14:56:30 +02:00
|
|
|
"wiki.phtanum-b.katzen.cafe" = {
|
|
|
|
group = "nginx";
|
|
|
|
keyType = "rsa4096";
|
|
|
|
};
|
2023-04-27 01:48:20 +02:00
|
|
|
"auth.katzen.cafe" = {
|
2023-04-26 23:25:04 +02:00
|
|
|
group = "nginx";
|
|
|
|
keyType = "rsa4096";
|
|
|
|
};
|
2023-05-03 00:01:02 +02:00
|
|
|
"design.katzen.cafe" = {
|
|
|
|
group = "nginx";
|
|
|
|
keyType = "rsa4096";
|
|
|
|
};
|
2023-04-26 23:25:04 +02:00
|
|
|
};
|
|
|
|
};
|
|
|
|
services.nginx = {
|
|
|
|
enable = true;
|
2023-05-03 00:01:02 +02:00
|
|
|
|
|
|
|
recommendedGzipSettings = true;
|
|
|
|
recommendedOptimisation = true;
|
|
|
|
recommendedTlsSettings = true;
|
|
|
|
recommendedProxySettings = true;
|
|
|
|
|
2023-04-26 23:25:04 +02:00
|
|
|
virtualHosts = {
|
2023-04-30 14:56:30 +02:00
|
|
|
"wiki.phtanum-b.katzen.cafe" = {
|
|
|
|
forceSSL = true;
|
|
|
|
enableACME = true;
|
|
|
|
locations."/" = {
|
|
|
|
proxyPass = "http://127.0.0.2:8081";
|
|
|
|
};
|
|
|
|
};
|
2023-04-26 23:25:04 +02:00
|
|
|
"auth.katzen.cafe" = {
|
|
|
|
forceSSL = true;
|
|
|
|
enableACME = true;
|
|
|
|
locations."/" = {
|
2023-04-30 14:56:30 +02:00
|
|
|
proxyPass = "http://127.0.0.1:8080";
|
2023-05-03 00:01:02 +02:00
|
|
|
extraConfig = ''
|
|
|
|
proxy_buffers 4 256k;
|
|
|
|
proxy_buffer_size 128k;
|
|
|
|
proxy_busy_buffers_size 256k;
|
|
|
|
proxy_set_header Host $host;
|
|
|
|
proxy_set_header X-Forwarded-Proto $scheme;
|
|
|
|
proxy_set_header X-Forwarded-For $proxy_protocol_addr;
|
|
|
|
proxy_set_header X-Real-IP $remote_addr;
|
|
|
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
#extraConfig = ''
|
|
|
|
#'';
|
|
|
|
};
|
|
|
|
"design.katzen.cafe" = {
|
|
|
|
forceSSL = true;
|
|
|
|
enableACME = true;
|
|
|
|
locations."/" = {
|
|
|
|
proxyPass = "http://localhost:9001";
|
|
|
|
proxyWebsockets = true;
|
2023-04-26 23:25:04 +02:00
|
|
|
};
|
|
|
|
};
|
2023-04-25 15:57:59 +02:00
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|