30 lines
528 B
Nix
30 lines
528 B
Nix
{
|
|
pkgs,
|
|
lib,
|
|
...
|
|
}: {
|
|
security.acme.certs = {
|
|
"benjaminbaedorf.eu" = {};
|
|
"b12f.io" = {};
|
|
};
|
|
|
|
services.nginx.virtualHosts = {
|
|
"benjaminbaedorf.eu" = {
|
|
forceSSL = true;
|
|
useACMEHost = "benjaminbaedorf.eu";
|
|
locations."/".return = "302 https://b12f.io$request_uri";
|
|
};
|
|
|
|
"b12f.io" = {
|
|
forceSSL = true;
|
|
useACMEHost = "b12f.io";
|
|
|
|
locations."/" = {
|
|
root = pkgs.b12f-io;
|
|
index = "index.html";
|
|
tryFiles = "$uri $uri/ =404";
|
|
};
|
|
};
|
|
};
|
|
}
|