krebs.git.cgit: make cache-root configurable

... along with all the other stuff :)
This commit is contained in:
tv 2016-06-07 03:14:21 +02:00
parent a1a4b1fe02
commit e37af74256
2 changed files with 21 additions and 19 deletions

View file

@ -7,9 +7,7 @@ let
rules = concatMap krebs-rules (attrValues krebs-repos) ++ concatMap priv-rules (attrValues priv-repos); rules = concatMap krebs-rules (attrValues krebs-repos) ++ concatMap priv-rules (attrValues priv-repos);
krebs-repos = mapAttrs make-krebs-repo { krebs-repos = mapAttrs make-krebs-repo {
brain = { brain = { };
desc = "braiiiins";
};
}; };
priv-repos = mapAttrs make-priv-repo { priv-repos = mapAttrs make-priv-repo {
@ -18,13 +16,13 @@ let
}; };
# TODO move users to separate module # TODO move users to separate module
make-priv-repo = name: { desc ? null, ... }: { make-priv-repo = name: { ... }: {
inherit name desc; inherit name;
public = false; public = false;
}; };
make-krebs-repo = with git; name: { desc ? null, ... }: { make-krebs-repo = with git; name: { ... }: {
inherit name desc; inherit name;
public = false; public = false;
hooks = { hooks = {
post-receive = pkgs.git-hooks.irc-announce { post-receive = pkgs.git-hooks.irc-announce {
@ -63,7 +61,7 @@ in {
imports = [ ]; imports = [ ];
krebs.git = { krebs.git = {
enable = true; enable = true;
cgit = false; cgit.enable = false;
inherit repos rules; inherit repos rules;
}; };
} }

View file

@ -10,17 +10,17 @@ let
krebs-repos = mapAttrs make-krebs-repo { krebs-repos = mapAttrs make-krebs-repo {
stockholm = { stockholm = {
desc = "Make all the systems into 1systems!"; cgit.desc = "Make all the systems into 1systems!";
}; };
tinc_graphs = { tinc_graphs = {
desc = "Tinc Advanced Graph Generation"; cgit.desc = "Tinc Advanced Graph Generation";
}; };
stockholm-init = { stockholm-init = {
desc = "Build new Stockholm hosts"; cgit.desc = "Build new Stockholm hosts";
}; };
cac-api = { }; cac-api = { };
init-stockholm = { init-stockholm = {
desc = "Init stuff for stockholm"; cgit.desc = "Init stuff for stockholm";
}; };
}; };
@ -32,19 +32,19 @@ let
connector = { }; connector = { };
minikrebs = { }; minikrebs = { };
mattermost = { mattermost = {
desc = "Mattermost Docker files"; cgit.desc = "Mattermost Docker files";
}; };
}; };
# TODO move users to separate module # TODO move users to separate module
make-priv-repo = name: { desc ? null, ... }: { make-priv-repo = name: { ... }: {
inherit name desc; inherit name;
public = false; public = false;
}; };
make-krebs-repo = with git; name: { desc ? null, ... }: { make-krebs-repo = with git; name: { cgit ? {}, ... }: {
inherit name desc; inherit cgit name;
public = true; public = true;
hooks = { hooks = {
post-receive = pkgs.git-hooks.irc-announce { post-receive = pkgs.git-hooks.irc-announce {
@ -88,8 +88,12 @@ let
in { in {
krebs.git = { krebs.git = {
enable = true; enable = true;
cgit = {
settings = {
root-title = "public repositories"; root-title = "public repositories";
root-desc = "keep on krebsing"; root-desc = "keep on krebsing";
};
};
inherit repos rules; inherit repos rules;
}; };
} }