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

Job restrictions can be skipped if no node block in Jenkinsfile

      Try following Jenkinsfile, it will always run on master, even you configured job restriction

      #!/usr/bin/env groovy
      timeout(time: 5, unit: 'MINUTES') {
        timestamps {
          properties([buildDiscarder(logRotator(daysToKeepStr: '7', artifactDaysToKeepStr: '0'))])
          stage('printing') {
            for ( i=1; i<10; i++ ) {
              println "Round ${i} checking"
              sleep 1
            }
          }
        }
      } 

          [JENKINS-55327] Job restrictions can be skipped if no node block in Jenkinsfile

          Joe Lee created issue -
          Oleg Nenashev made changes -
          Link New: This issue relates to JENKINS-46652 [ JENKINS-46652 ]
          Oleg Nenashev made changes -
          Component/s New: core [ 15593 ]
          Oleg Nenashev made changes -
          Labels New: regression
          Oleg Nenashev made changes -
          Labels Original: regression
          Daniel Beck made changes -
          Resolution New: Won't Fix [ 2 ]
          Status Original: Open [ 1 ] New: Closed [ 6 ]

            Unassigned Unassigned
            joelee Joe Lee
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: