From 9999dc90758cb9d55ab13d38335818b611910ebf Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Wed, 13 Jan 2016 00:27:43 +0100 Subject: first stab at system config --- ymir.nix | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/ymir.nix b/ymir.nix index 0c1bf437..8676b0f1 100644 --- a/ymir.nix +++ b/ymir.nix @@ -170,6 +170,32 @@ in rec { enable = true; httpConfig = builtins.readFile ./custom/ymir.nginx; }; + users.extraUsers."nginx".extraGroups = ["uwsgi"]; + + services.uwsgi = { + enable = true; + plugins = ["cgi"]; + instance = { + type = "normal"; + processes = 1; + threads = 8; + cgi = "${pkgs.cgit}/bin/cgit"; + }; + }; + + users.extraUsers."uwsgi".extraGroups = ["git"]; + + environment.etc."cgitrc" = { + enable = true; + text = '' + robots=noindex, nofollow + virtual-root=/ + enable-git-config=1 + + project-list=/srv/git/projects.list + scan-path=/srv/git/repositories + ''; + }; services.gitolite = { enable = true; -- cgit v1.2.3