This issue is archived. You can view it, but you can't modify it. Learn more

ExportXMLWordPrintable

      Maybe this is true of agent any too (did not check), but saw that if you do something like

      pipeline {
        options {
          skipDefaultCheckout()
          // I think I had a timeout here too
        }
        agent {
          docker {
            image 'whatever'
          }
        }
        stages {
          stage('x') {
            steps {
              checkout scm
              sh '...'
            }
          }
        }
        post {
          failure {
            archiveArtifacts artifacts: '...', allowEmptyArchive: true
          }
        }
      }
      

      and the sh step fails, you get an error message complaining that archiveArtifacts must be run inside a node block.

            Assignee:
            Unassigned
            Reporter:
            Jesse Glick
            Archiver:
            Jenkins Service Account

              Created:
              Updated:
              Archived: