infra/pastila/srv.nix
2024-06-01 13:22:49 +02:00

27 lines
498 B
Nix

{ config, lib, pkgs, ... }:
{
services.nginx.enable = true;
users.users."up" = {
isNormalUser = true;
group = config.services.nginx.group;
createHome = true;
};
services.nginx.virtualHosts."srv.isomorphis.me" = {
forceSSL = true;
enableACME = true;
root = config.users.users."up".home;
locations."/" = {
extraConfig = ''
autoindex on;
'';
};
locations."/i/" = {
extraConfig = ''
autoindex off;
'';
};
};
}