Tag: jenkins

Jenkins deploy per branch

I have a PHP application that will be using Jenkins and GitHub to automatically deploy every time when pushed. I am working on a branch so if I push any changes I want to deploy to branch.test.com and see the changes right away. I am trying to use “Execute Shell” in Jenkins so after build, […]

Jenkins: pass git commit hash to a downstream job

I have 2 jobs (A and B). Job A points to a git repo at URL-A. Job B points to a different git repo, at URL-B. Once job A finishes and is stable, it should trigger job B and pass the git commit hash that was used in job A’s build. What is the simplest […]

hudson.util.HudsonFailedToLoad error in Jenkins

I am getting below error when i am trying to access my Jenkins server, hudson.util.HudsonFailedToLoad: org.jvnet.hudson.reactor.ReactorException: java.lang.Error: java.lang.reflect.InvocationTargetException at hudson.WebAppMain$3.run(WebAppMain.java:234) Caused by: org.jvnet.hudson.reactor.ReactorException: java.lang.Error: java.lang.reflect.InvocationTargetException at org.jvnet.hudson.reactor.Reactor.execute(Reactor.java:269) at jenkins.InitReactorRunner.run(InitReactorRunner.java:44) at jenkins.model.Jenkins.executeReactor(Jenkins.java:910) at jenkins.model.Jenkins.<init>(Jenkins.java:809) at hudson.model.Hudson.<init>(Hudson.java:82) at hudson.model.Hudson.<init>(Hudson.java:78) at hudson.WebAppMain$3.run(WebAppMain.java:222) Caused by: java.lang.Error: java.lang.reflect.InvocationTargetException at hudson.init.TaskMethodFinder.invoke(TaskMethodFinder.java:109) at hudson.init.TaskMethodFinder$TaskImpl.run(TaskMethodFinder.java:169) at org.jvnet.hudson.reactor.Reactor.runTask(Reactor.java:282) at jenkins.model.Jenkins$7.runTask(Jenkins.java:899) at org.jvnet.hudson.reactor.Reactor$2.run(Reactor.java:210) at org.jvnet.hudson.reactor.Reactor$Node.run(Reactor.java:117) […]

git clone gets hung and gets timedout

I use Bitbucket(git) server and currently the git clone is randomly getting hung. The same repo sometimes gets cloned and sometimes get hung unexpectedly and then gets timed out. The server memory, CPU utilization, disk space is fine. Please advise what could be other areas that needs attention to find the root cause.This is happening […]

For the Jenkins git plugin, where is it recommended to run `git config`?

Under Jenkins I am having the same longpaths issue described in this thread. This git config –system core.longpaths true solution is supposed to fix the issue for me (I have not tried it yet), but… where do I place it? The answer states “You should be able to run the command… or add it to […]

Jenkins Branches to Build – Exclude Single Branch

Currently, using the setup displayed below, Jenkins builds master and all *-preview branches. Using Branches to build, is it possible for Jenkins to exclude a single *-preview branch such as exclude-this-branch-preview while building all remaining *-preview branches?

How to let Jenkins git commit only if there are changes?

I have a Jenkins job that builds from a github.com repository’s master branch with Maven (mvn clean install), then checks for license headers in Java files and missing NOTICE files, and adds them if necessary (mvn license:format notice:generate). Sometimes this will result in changed or added files, sometimes not. Whenever there have any changes been […]

How do I build from a Git repository subdirectory with Jenkins & Ant?

I have Jenkins CI configured to work with GitHub. It successfully populates my ${workspace} but the actual project I want to build is in a subdirectory of the repo: https://github.com/androidfu/CodeExamples Invoking Ant from within Jenkins states that it can’t find build.xml. Well, that’s because build.xml actually exists in ${workspace}/DeveloperDebugPreferences.

Git ls-remote and git update with Crowd authentication

I have switched my Git repos to authenticate with Crowd instead of basic authentication. It’s all working great when anyone can authenticate, but I have problems with two commands, any ideas how to solve it? git ls-remote -h HEAD I do not have a way to specify any credentials here (it’s in Jenkins) git remote […]

jenkins complains host key verification failure although the key was generated

Error: Fetching upstream changes from git@github.com:……/………git ERROR: Problem fetching from origin / origin – could be unavailable. Continuing anyway hudson.plugins.git.GitException: Error performing command: git fetch -t git@github.com:……/……git +refs/heads/*:refs/remotes/origin/* Command “git fetch -t git@github.com:…../……git +refs/heads/*:refs/remotes/origin/*” returned status code 128: Host key verification failed. fatal: The remote end hung up unexpectedly My comments: I found that jenkins […]

Git Baby is a git and github fan, let's start git clone.