nix-config/modules/me/default.nix
2025-05-13 15:12:33 +02:00

29 lines
551 B
Nix

{
lib,
config,
...
}: let
inherit (lib) mkIf;
cfg = config.conf.website;
me = {
name = "mira";
};
in
mkIf cfg.enable {
services.nginx.virtualHosts = {
${cfg.domain.me} = {
default = true;
serverName = cfg.domain.me;
useACMEHost = cfg.domain.base;
forceSSL = true;
locations = {
"/about.json" = {
return = builtins.toJson me;
extraConfig = ''
default_type application/json;
'';
};
};
};
};
}