niksos/hosts/chmura/services/forgejo.nix

35 lines
814 B
Nix
Raw Normal View History

2023-10-03 19:22:24 +02:00
{
config,
...
}: {
services.forgejo = {
enable = true;
lfs.enable = true;
database.type = "postgres";
dump = {
enable = true;
type = "tar.xz";
};
settings = {
DEFAULT = {
APP_NAME = "fuck it we code";
};
2024-03-06 19:05:39 +01:00
server = rec {
2023-10-03 19:22:24 +02:00
DOMAIN = "git.jacekpoz.pl";
HTTP_PORT = 1849;
PROTOCOL = "http";
SSH_PORT = 8236;
2024-03-06 19:05:39 +01:00
ROOT_URL = "${PROTOCOL}://${DOMAIN}/";
2023-10-03 19:22:24 +02:00
};
};
};
services.caddy = {
enable = true;
virtualHosts."git.jacekpoz.pl".extraConfig = ''
2024-03-06 19:05:39 +01:00
reverse_proxy * localhost:${toString config.services.forgejo.settings.server.HTTP_PORT}
2023-10-03 19:22:24 +02:00
'';
};
}