git stuff
This commit is contained in:
parent
97134ce956
commit
33c551c0b2
2 changed files with 26 additions and 3 deletions
|
|
@ -1,13 +1,34 @@
|
|||
{ pkgs, var, ... }:
|
||||
let
|
||||
gitpath = "/git";
|
||||
in
|
||||
{
|
||||
programs.git.enable = true;
|
||||
users.groups.git = { };
|
||||
users.users.git = {
|
||||
isSystemUser = true;
|
||||
home = "/git";
|
||||
home = gitpath;
|
||||
homeMode = "755";
|
||||
createHome = true;
|
||||
group = "git";
|
||||
shell = "${pkgs.git}/bin/git-shell";
|
||||
openssh.authorizedKeys.keys = var.ssh-keys.hd;
|
||||
password = "!";
|
||||
};
|
||||
|
||||
services =
|
||||
let
|
||||
cgit-host = "git.lan";
|
||||
in
|
||||
{
|
||||
nginx = {
|
||||
privateVirtualHosts.${cgit-host} = { };
|
||||
};
|
||||
cgit."git" = {
|
||||
group = "git";
|
||||
enable = true;
|
||||
scanPath = gitpath;
|
||||
nginx.virtualHost = cgit-host;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue