nicks-nix-config/hosts/Alaska/modules/atuin.nix

33 lines
612 B
Nix
Raw Normal View History

2024-01-09 18:47:47 -08:00
{ config, ...}:
let
in
{
services.atuin = {
enable = true;
openFirewall = true;
port = 8910;
host = "127.0.0.1";
openRegistration = true;
database = {
createLocally = true;
};
};
services.nginx.virtualHosts = {
"atuin.nickiel.net" = {
forceSSL = true;
enableACME = true;
locations."/" = {
2024-01-09 19:27:51 -08:00
proxyPass = "http://127.0.0.1:${builtins.toString config.services.atuin.port}";
2024-01-09 18:47:47 -08:00
proxyWebsockets = true;
extraConfig = ''
allow 100.64.0.0/16;
allow 127.0.0.1;
deny all;
'';
};
};
};
}