Use idleMinutes in declarative pipelines

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

XMLWordPrintable

      We would like to use the option idleMinutes in declaratives pipelines.

      Indeed, we would like to reuse the created pod for other builds, since it takes some time to instantiate.

      We tried this, but were unsuccessful :

       

      agent {
        kubernetes {
          label 'mylabel'
          defaultContainer 'jnlp'
          yaml '''
      apiVersion: v1
      kind: Pod
      metadata:
       labels:
       some-label: some-label-value
      spec:
       containers:
       - name: jnlp
       image: my-docker.corp:42/jnlp:3.7-1-alpine
       args: 
       - ${computer.jnlpmac} ${computer.name}
       tty: true
       idleMinutes: 20
      '''

       

      Is there a way to do so ? If no, that would be a great feature !

      Thanks !

            Assignee:
            Carlos Sanchez
            Reporter:
            Tom Marcuzzi
            Archiver:
            Jenkins Service Account

              Created:
              Updated:
              Resolved:
              Archived: