Skip to content

Commit

Permalink
gitlab-module: fix hooks links for older repositories
Browse files Browse the repository at this point in the history
(cherry picked from commit 4147207)
  • Loading branch information
ciil authored and globin committed Oct 22, 2017
1 parent c5ce2b5 commit aac85e1
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions nixos/modules/services/misc/gitlab.nix
Expand Up @@ -632,6 +632,11 @@ in {
touch "${cfg.statePath}/db-seeded"
fi
# The gitlab:shell:create_hooks task seems broken for fixing links
# so we instead delete all the hooks and create them anew
rm ${cfg.statePath}/repositories/**/*.git/hooks
${gitlab-rake}/bin/gitlab-rake gitlab:shell:create_hooks RAILS_ENV=production
# Change permissions in the last step because some of the
# intermediary scripts like to create directories as root.
chown -R ${cfg.user}:${cfg.group} ${cfg.statePath}
Expand Down

0 comments on commit aac85e1

Please sign in to comment.