server-configs/machines/gerd/services/fricloud-website.nix
2024-08-23 15:22:07 +02:00

29 lines
877 B
Nix

{ config, pkgs, ... }:
let
svc_domain = config.mine.shared.settings.domain;
in {
services.nginx.virtualHosts."${svc_domain}" = {
forceSSL = true;
enableACME = true;
root = pkgs.writeTextDir "index.html" ''
<html>
<head>
<title>${svc_domain}</title>
</head>
<body>
<marquee
direction="down"
behavior="alternate">
<marquee behavior="alternate"><a href="/members">Under Construction</a></marquee>
</marquee>
</body>
</html>
'';
};
# setup group for fricloud.dk cert + add nginx to group.
# group `main-domain` is used for users that need access to the domain certificate, e.g. murmur
security.acme.certs."${svc_domain}".group = config.users.groups.main-domain.name;
users.groups.main-domain.members = [ config.users.users.nginx.name ];
}