forked from DGNum/infrastructure
feat(plausible): Transfer from web01 to compute01
This commit is contained in:
parent
fd6674fd5d
commit
f065db687a
11 changed files with 63 additions and 88 deletions
53
machines/compute01/plausible.nix
Normal file
53
machines/compute01/plausible.nix
Normal file
|
@ -0,0 +1,53 @@
|
|||
{ config, ... }:
|
||||
|
||||
let
|
||||
host = "analytics.dgnum.eu";
|
||||
port = 8111;
|
||||
in
|
||||
|
||||
{
|
||||
services.plausible = {
|
||||
enable = true;
|
||||
|
||||
mail = {
|
||||
email = "analytics@infra.dgnum.eu";
|
||||
|
||||
smtp = {
|
||||
user = "web-services@infra.dgnum.eu";
|
||||
passwordFile = config.age.secrets."plausible-smtp_password_file".path;
|
||||
hostPort = 465;
|
||||
hostAddr = "kurisu.lahfa.xyz";
|
||||
enableSSL = true;
|
||||
};
|
||||
};
|
||||
|
||||
server = {
|
||||
baseUrl = "https://${host}";
|
||||
inherit port;
|
||||
|
||||
disableRegistration = false;
|
||||
|
||||
secretKeybaseFile = config.age.secrets."plausible-secret_key_base_file".path;
|
||||
};
|
||||
|
||||
adminUser = {
|
||||
passwordFile = config.age.secrets."plausible-admin_user_password_file".path;
|
||||
email = "tom.hubrecht@dgnum.eu";
|
||||
name = "thubrecht";
|
||||
activate = true;
|
||||
};
|
||||
};
|
||||
|
||||
services.nginx = {
|
||||
enable = true;
|
||||
|
||||
virtualHosts.${host} = {
|
||||
enableACME = true;
|
||||
forceSSL = true;
|
||||
|
||||
locations."/" = {
|
||||
proxyPass = "http://127.0.0.1:${builtins.toString port}";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue