Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-53624

Branch indexing schedules builds for other branches and repos

      Hello,

      I'm having a problem that seems pretty much identical to this one for the Gitlab Branch Source Plugin: https://github.com/Argelbargel/gitlab-branch-source-plugin/issues/45

      I'm assuming the root issue is very similar, if not identical. On Github webhook triggers a number of branch indexing jobs are kicked off for builds in the current repo, as well as for other repos. I'm using BlueOcean.

      Questions:

      1) Is this a known issue?

      2) Is there a workaround?

      3) As a possible means to come up with a workaround, are there any variables I can latch onto that would give me visibility into the context so in my Jenkinsfile pipeline I can do the following on branch indexing:

      currentBuild.result = 'NOT_BUILT'
      error('Aborting build triggered by scan process')

      This was a suggestion in the above Gitlab thread, only I'm not seeing an equivalent to `gitlabActionType` in the list of environment variables (output with "env"). It would be great if I could ignore builds from branch indexing as a short term workaround without disabling the webhooks entirely.

          [JENKINS-53624] Branch indexing schedules builds for other branches and repos

          Joe Auty created issue -
          Joe Auty made changes -
          Description Original: Hello,

          I'm having a problem that seems pretty much identical to this one for the Gitlab Branch Source Plugin: [https://github.com/Argelbargel/gitlab-branch-source-plugin/issues/45]

          I'm assuming the root issue is very similar, if not identical. On Github webhook triggers a number of branch indexing jobs are kicked off for builds in other repos. I'm using BlueOcean.

          Questions:

          1) Is this a known issue?

          2) Is there a workaround?

          3) As a possible means to come up with a workaround, are there any variables I can latch onto that would give me visibility into the context so in my Jenkinsfile pipeline I can:


          {noformat}
          currentBuild.result = 'NOT_BUILT'
          error('Aborting build triggered by scan process'){noformat}

          This was a suggestion in the above Gitlab thread, only I'm not seeing an equivalent to `gitlabActionType` in the list of environment variables (output with "env"). It would be great if I could ignore builds from branch indexing as a short term workaround.
          New: Hello,

          I'm having a problem that seems pretty much identical to this one for the Gitlab Branch Source Plugin: [https://github.com/Argelbargel/gitlab-branch-source-plugin/issues/45]

          I'm assuming the root issue is very similar, if not identical. On Github webhook triggers a number of branch indexing jobs are kicked off for builds in other repos. I'm using BlueOcean.

          Questions:

          1) Is this a known issue?

          2) Is there a workaround?

          3) As a possible means to come up with a workaround, are there any variables I can latch onto that would give me visibility into the context so in my Jenkinsfile pipeline I can do the following on branch indexing:
          {noformat}
          currentBuild.result = 'NOT_BUILT'
          error('Aborting build triggered by scan process'){noformat}
          This was a suggestion in the above Gitlab thread, only I'm not seeing an equivalent to `gitlabActionType` in the list of environment variables (output with "env"). It would be great if I could ignore builds from branch indexing as a short term workaround.
          Joe Auty made changes -
          Description Original: Hello,

          I'm having a problem that seems pretty much identical to this one for the Gitlab Branch Source Plugin: [https://github.com/Argelbargel/gitlab-branch-source-plugin/issues/45]

          I'm assuming the root issue is very similar, if not identical. On Github webhook triggers a number of branch indexing jobs are kicked off for builds in other repos. I'm using BlueOcean.

          Questions:

          1) Is this a known issue?

          2) Is there a workaround?

          3) As a possible means to come up with a workaround, are there any variables I can latch onto that would give me visibility into the context so in my Jenkinsfile pipeline I can do the following on branch indexing:
          {noformat}
          currentBuild.result = 'NOT_BUILT'
          error('Aborting build triggered by scan process'){noformat}
          This was a suggestion in the above Gitlab thread, only I'm not seeing an equivalent to `gitlabActionType` in the list of environment variables (output with "env"). It would be great if I could ignore builds from branch indexing as a short term workaround.
          New: Hello,

          I'm having a problem that seems pretty much identical to this one for the Gitlab Branch Source Plugin: [https://github.com/Argelbargel/gitlab-branch-source-plugin/issues/45]

          I'm assuming the root issue is very similar, if not identical. On Github webhook triggers a number of branch indexing jobs are kicked off for builds in the current repo, as well as for other repos. I'm using BlueOcean.

          Questions:

          1) Is this a known issue?

          2) Is there a workaround?

          3) As a possible means to come up with a workaround, are there any variables I can latch onto that would give me visibility into the context so in my Jenkinsfile pipeline I can do the following on branch indexing:
          {noformat}
          currentBuild.result = 'NOT_BUILT'
          error('Aborting build triggered by scan process'){noformat}
          This was a suggestion in the above Gitlab thread, only I'm not seeing an equivalent to `gitlabActionType` in the list of environment variables (output with "env"). It would be great if I could ignore builds from branch indexing as a short term workaround.
          Joe Auty made changes -
          Description Original: Hello,

          I'm having a problem that seems pretty much identical to this one for the Gitlab Branch Source Plugin: [https://github.com/Argelbargel/gitlab-branch-source-plugin/issues/45]

          I'm assuming the root issue is very similar, if not identical. On Github webhook triggers a number of branch indexing jobs are kicked off for builds in the current repo, as well as for other repos. I'm using BlueOcean.

          Questions:

          1) Is this a known issue?

          2) Is there a workaround?

          3) As a possible means to come up with a workaround, are there any variables I can latch onto that would give me visibility into the context so in my Jenkinsfile pipeline I can do the following on branch indexing:
          {noformat}
          currentBuild.result = 'NOT_BUILT'
          error('Aborting build triggered by scan process'){noformat}
          This was a suggestion in the above Gitlab thread, only I'm not seeing an equivalent to `gitlabActionType` in the list of environment variables (output with "env"). It would be great if I could ignore builds from branch indexing as a short term workaround.
          New: Hello,

          I'm having a problem that seems pretty much identical to this one for the Gitlab Branch Source Plugin: [https://github.com/Argelbargel/gitlab-branch-source-plugin/issues/45]

          I'm assuming the root issue is very similar, if not identical. On Github webhook triggers a number of branch indexing jobs are kicked off for builds in the current repo, as well as for other repos. I'm using BlueOcean.

          Questions:

          1) Is this a known issue?

          2) Is there a workaround?

          3) As a possible means to come up with a workaround, are there any variables I can latch onto that would give me visibility into the context so in my Jenkinsfile pipeline I can do the following on branch indexing:
          {noformat}
          currentBuild.result = 'NOT_BUILT'
          error('Aborting build triggered by scan process'){noformat}
          This was a suggestion in the above Gitlab thread, only I'm not seeing an equivalent to `gitlabActionType` in the list of environment variables (output with "env"). It would be great if I could ignore builds from branch indexing as a short term workaround without disabling the webhooks entirely.

            lanwen Kirill Merkushev
            joeauty Joe Auty
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: