about summary refs log tree commit diff
path: root/hosts/common/server
diff options
context:
space:
mode:
Diffstat (limited to 'hosts/common/server')
-rw-r--r--hosts/common/server/gitea.nix27
1 files changed, 27 insertions, 0 deletions
diff --git a/hosts/common/server/gitea.nix b/hosts/common/server/gitea.nix
new file mode 100644
index 0000000..83380a0
--- /dev/null
+++ b/hosts/common/server/gitea.nix
@@ -0,0 +1,27 @@
+{ config, pkgs, lib, ... }:
+
+let cfg = config.services.gitea;
+in {
+  users.users.git = {
+    description = "Gitea Service";
+    home = cfg.stateDir;
+    useDefaultShell = true;
+    group = "git";
+    isSystemUser = true;
+  };
+  users.groups.git = { };
+
+  services.gitea = {
+    enable = true;
+    user = "git";
+    domain = "git.fcuny.net";
+    appName = "${cfg.domain}";
+    rootUrl = "https://${cfg.domain}/";
+    httpAddress = "127.0.0.1";
+    httpPort = 8002;
+    log.level = "Error";
+    settings = { other.SHOW_FOOTER_VERSION = false; };
+    dump.enable = false;
+    database = { type = "sqlite3"; };
+  };
+}