Variable resolution in GString fails for docker args

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

XMLWordPrintable

      agent {
        docker {
          image 'maven:3-alpine'
          args "-v ${HOME}/.m2:/root/.m2"
        }
       }

      Fails with compilation error
      groovy.lang.MissingPropertyException: No such property: HOME for class: groovy.lang.Binding
      The HOME env var should technically be there in runtime since we are inside a node block

            Assignee:
            Andrew Bayer
            Reporter:
            rsandell
            Archiver:
            Jenkins Service Account

              Created:
              Updated:
              Resolved:
              Archived: