I am using jenkins to build my git remote project. The problem is log says \'timeout after 10 min\'. Receiving object starts and at 56% something happens.
As @edison-medina mentions, increasing the timeout may help but in my case the shallow clone was a better option. The shallow clone will dramatically reduce the time needed to clone a repo, specially one that has been growing for some time and may have hundreds or thousands of commits per file, because you'll only fetch the file version history indicated by the "depth" parameter on the clone
command. For most CI use-cases, using "1" is the best option since only the latest version of a file is needed to complete a build.
To set this up in Jenkins, you'll need to open your project's configuration screen and find the section on Git, click the "Add" button under "Additional Behaviors", and select "Advanced clone behaviors". Check the "Shallow clone" option and set the depth to "1".
You'll need to do this for each project in Jenkins. I haven't seen a way to do this globally for all projects.
I have also face the same error while click on Build Now Button in Jenkins.
Why this error comes ? Ans: This error was coming because of low Internet connection or may be the size of you project in github is large, so jenkins not able load/cone that project from git server.
Solution steps:
git
.Add
button and select Advanced clone behaviors
.Timeout
(in minutes) for clone and fetch operations box put any number which is more then 10, (I put 60 here).Cheers :)
Edit your job configuration, and under git plugin section:
I recommend checking also the "shallow clone" option. It fetches only the last state of the repository (without the history), so it's much faster.