mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-10-04 19:48:34 +03:00
nixos/sourcehut: fix links to gitsrht-update-hook
This commit is contained in:
parent
ac2a39ac75
commit
e1549f5df9
@ -1004,6 +1004,15 @@ in
|
|||||||
inherit configIniOfService;
|
inherit configIniOfService;
|
||||||
mainService = mkMerge [ baseService {
|
mainService = mkMerge [ baseService {
|
||||||
serviceConfig.StateDirectory = [ "sourcehut/gitsrht" "sourcehut/gitsrht/repos" ];
|
serviceConfig.StateDirectory = [ "sourcehut/gitsrht" "sourcehut/gitsrht/repos" ];
|
||||||
|
preStart = mkIf (!versionAtLeast config.system.stateVersion "22.05") (mkBefore ''
|
||||||
|
# Fix Git hooks of repositories pre-dating https://github.com/NixOS/nixpkgs/pull/133984
|
||||||
|
(
|
||||||
|
set +f
|
||||||
|
shopt -s nullglob
|
||||||
|
for h in /var/lib/sourcehut/gitsrht/repos/~*/*/hooks/{pre-receive,update,post-update}
|
||||||
|
do ln -fnsv /usr/bin/gitsrht-update-hook "$h"; done
|
||||||
|
)
|
||||||
|
'');
|
||||||
} ];
|
} ];
|
||||||
port = 5001;
|
port = 5001;
|
||||||
webhooks = true;
|
webhooks = true;
|
||||||
|
Loading…
Reference in New Issue
Block a user