Import the gitlab-shell "gitlab projects" functionality into GitLab CE
Copy gitlab-shell/lib/gitlab_projects.rb into gitlab-ce/lib/gitlab/git/gitlab_projects.rb (or so)
Old description:
Currently, gitlab-shell uses SIGKILL
unconditionally if any of its git subprocesses exceed the user-specified timeout. This can lead to corruption of the repository and is generally a bad idea.
Instead, we should send SIGTERM
, wait ~5 seconds, then send SIGKILL
if the process hasn't died in that time period. For bonus points, if the gitlab-shell subprocess receives an INT
, TERM
or similar signal, it should also kill its children before exiting.
There are commands where we allow the subprocess to run without any timeouts at all (e.g., gitlab-projects fork-repository
). These should be fixed.
Edited by Nick Thomas