diff --git a/nixos-apps/git.ewanick.com.nix b/nixos-apps/git.ewanick.com.nix index f086848..4b024df 100644 --- a/nixos-apps/git.ewanick.com.nix +++ b/nixos-apps/git.ewanick.com.nix @@ -2,45 +2,62 @@ let baseUrl = "git.ewanick.com"; in { - services.gitea = { + services.forgejo = { enable = true; - appName = "Bill's Gitea server, hosted on Linode using NixOS"; + appName = "Bill's Forgejo server, hosted on Linode using NixOS"; + database.type = "postgres"; + # Enable support for Git Large File Storage + lfs.enable = true; settings = { server = { DOMAIN = baseUrl; ROOT_URL = "https://${baseUrl}/"; HTTP_PORT = 3000; }; - service = { - DISABLE_REGISTRATION = true; + service.DISABLE_REGISTRATION = true; + + # Add support for actions, based on act: https://github.com/nektos/act + actions = { + ENABLED = true; + DEFAULT_ACTIONS_URL = "github"; }; - # actions = { + # Sending emails is completely optional + # You can send a test email from the web UI at: + # Profile Picture > Site Administration > Configuration > Mailer Configuration + # mailer = { # ENABLED = true; - # DEFAULT_ACTIONS_URL = "self"; + # SMTP_ADDR = "mail.example.com"; + # FROM = "noreply@${srv.DOMAIN}"; + # USER = "noreply@${srv.DOMAIN}"; # }; }; + # secrets = { + # mailer.PASSWD = config.age.secrets.forgejo-mailer-password.path; + # }; }; - # services.gitea-actions-runner.instances = { - # "first-runner" = { - # enable = true; - # url = baseUrl; - # tokenFile = ./git.ewanick.com/tokenFile; - # hostPackages = with pkgs; [ - # bash - # coreutils - # curl - # gawk - # gitMinimal - # gnused - # wget - # ]; - # name = "linode-nixos"; - # labels = [ - # "native:host" - # ]; - # }; - # }; + services.gitea-actions-runner = { + package = pkgs.forgejo-runner; + instances.default = { + enable = true; + name = "linode-nixos"; + url = baseUrl; + tokenFile = ./git.ewanick.com/tokenFile; + hostPackages = with pkgs; [ + bash + coreutils + curl + gawk + gitMinimal + gnused + wget + ]; + + labels = [ + "native:host" + ]; + }; + }; services.caddy = { enable = true;