diff --git a/hosts/sakura/services/forgejo.nix b/hosts/sakura/services/forgejo.nix index 14d14a6..7563ac8 100644 --- a/hosts/sakura/services/forgejo.nix +++ b/hosts/sakura/services/forgejo.nix @@ -1,11 +1,17 @@ -{pkgs, ...}: { +{ + pkgs, + config, + lib, + ... +}: { + sops.secrets.forgejo-db = {}; services.gitea = { enable = true; package = pkgs.forgejo; appName = "forgejo"; - stateDir = "/sakura/forgejo"; + stateDir = "/var/lib/forgejo"; settings = { - service.DISABLE_REGISTRATION = true; + service.DISABLE_REGISTRATION = false; ui = { DEFAULT_THEME = "forgejo-dark"; }; @@ -19,6 +25,13 @@ ROOT_URL = "https://git.notohh.dev"; LANDING_PAGE = "/explore/repos"; }; + database = { + DB_TYPE = lib.mkForce "postgres"; + HOST = "192.168.1.211:5432"; + NAME = "forgejo"; + USER = "forgejo"; + PASSWD = "forgejo"; + }; }; }; }