1
votes

I'm in trouble setting up Jenkins to trigger a build on a GitHub push. Here's the config of my Jenkins job (the build is here only a touch /tmp/JENKINS_WORKS for testing purpose) :

<?xml version='1.0' encoding='UTF-8'?>
<project>
  <actions/>
  <description>&lt;!-- Managed by Jenkins Job Builder --&gt;</description>
  <keepDependencies>false</keepDependencies>
  <properties>
    <com.coravy.hudson.plugins.github.GithubProjectProperty plugin="[email protected]">
      <projectUrl>https://github.com/Mean-Street/cloud_native_app/</projectUrl>
      <displayName></displayName>
    </com.coravy.hudson.plugins.github.GithubProjectProperty>
  </properties>
  <scm class="hudson.plugins.git.GitSCM" plugin="[email protected]">
    <configVersion>2</configVersion>
    <userRemoteConfigs>
      <hudson.plugins.git.UserRemoteConfig>
        <url>https://github.com/Mean-Street/cloud_native_app.git</url>
      </hudson.plugins.git.UserRemoteConfig>
    </userRemoteConfigs>
    <branches>
      <hudson.plugins.git.BranchSpec>
        <name>**</name>
      </hudson.plugins.git.BranchSpec>
    </branches>
    <doGenerateSubmoduleConfigurations>false</doGenerateSubmoduleConfigurations>
    <submoduleCfg class="list"/>
    <extensions/>
  </scm>
  <canRoam>true</canRoam>
  <disabled>false</disabled>
  <blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding>
  <blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding>
  <triggers>
    <com.cloudbees.jenkins.GitHubPushTrigger plugin="[email protected]">
      <spec></spec>
    </com.cloudbees.jenkins.GitHubPushTrigger>
  </triggers>
  <concurrentBuild>false</concurrentBuild>
  <builders>
    <hudson.tasks.Shell>
      <command>touch /tmp/JENKINS_WORKS</command>
    </hudson.tasks.Shell>
  </builders>
  <publishers/>
  <buildWrappers/>
</project>

I configured the webhook on GitHub, which works fine as I see on GitHub that Jenkins answers 200 OK. But Jenkins does not trigger this build, so I guess it's a Jenkins configuration problem. Any idea of what could be the problem ?

As the repo is a public one, I thought I don't need to give any credentials to Jenkins to access it, is that right ?

Thanks in advance for any help or advice.

1
I have the same problem with a similar configuration. I hope someone can find the solution fast. - PiggyGenius

1 Answers

1
votes

This is a jenkins Github plugin issue. https://issues.jenkins-ci.org/browse/JENKINS-49332

I had this issue with 1.0.29 downgrade to 1.0.27 should fix your issue.