nixos-config/services/gitea.nix

36 lines
787 B
Nix
Raw Normal View History

2024-03-05 09:16:28 +00:00
{ config, ... }:
{
2024-03-07 05:34:47 +00:00
services.nginx.virtualHosts."git.skymath.duckdns.org" = {
enableACME = true;
forceSSL = true;
2024-03-05 09:16:28 +00:00
locations."/" = {
proxyPass = "http://localhost:3001/";
};
};
services.postgresql = {
ensureDatabases = [ config.services.gitea.user ];
ensureUsers = [
{
name = config.services.gitea.database.user;
ensureDBOwnership = true;
}
];
};
services.gitea = {
enable = true;
appName = "Fallingsky04's Gitea Server <3"; # Give the site a name
2024-03-05 09:16:28 +00:00
database = {
type = "postgres";
2024-04-04 21:10:42 +00:00
passwordFile = "/run/keys/gitea-dbpassword";
2024-03-05 09:16:28 +00:00
};
settings.server = {
2024-03-08 04:47:08 +00:00
DOMAIN = "git.skymath.duckdns.org";
ROOT_URL = "https://git.skymath.duckdns.org/";
2024-03-05 09:16:28 +00:00
HTTP_PORT = 3001;
};
};
}