adyya-flake/services/forgejo/forgejo.mod.nix
Ittihadyya d32ef70d08
All checks were successful
/ nix fmt (push) Successful in 48s
/ Update .lock file (push) Successful in 1m56s
semicolon
2024-11-26 15:50:00 +02:00

53 lines
1.5 KiB
Nix

{
fructose.modules = [
(
{
config,
pkgs,
...
}: {
services.forgejo = {
enable = true;
package = pkgs.forgejo;
stateDir = "/var/services/forgejo";
useWizard = false;
database = {
createDatabase = false;
type = "postgres";
name = "forgejodb";
host = "127.0.0.1";
port = 5432;
user = "forgejo";
passwordFile = "${config.sops.secrets.forgejo_db_pass.path}";
};
dump = {
enable = true;
interval = "02:50";
type = "tar.gz";
};
settings = {
# this directly drops stuff in the forgejo app.ini
server = {
DOMAIN = "git.collective-conciousness.monster";
PROTOCOL = "http";
HTTP_PORT = 3000;
SSH_PORT = 222;
ROOT_URL = "https://${config.services.forgejo.settings.server.DOMAIN}:443";
ENABLE_GZIP = true;
};
service = {
DISABLE_REGISTRATION = true;
DEFAULT_KEEP_EMAIL_PRIVATE = true;
};
actions = {
DEFAULT_ACTIONS_URL = "https://github.com"; # i have to do this because some actions call other actions, and most of those call github actions. ideally this would be "https://git.collective-conciousness.monster"
};
};
};
}
)
];
}