diff --git a/module.nix b/module.nix index eee423b..2926040 100644 --- a/module.nix +++ b/module.nix @@ -96,7 +96,6 @@ in enable = true; database.type = "sqlite3"; host = "${cfg.subdomain}.${sp.domain}"; - nginx.enable = true; settings = { server.port = 8081; app = { @@ -144,6 +143,16 @@ in }; }; + services.nginx.virtualHosts."${cfg.subdomain}.${sp.domain}" = { + useACMEHost = sp.domain; + forceSSL = true; + locations = { + "/" = { + proxyPass = "http://127.0.0.1:8081"; + }; + }; + }; + selfprivacy.auth.clients.${oauthClientID} = { inherit usersGroup; subdomain = cfg.subdomain;