1.mail

As an example of loading variable values from Groovy:

mail to: 'devops@acme.com',
    subject: "Job '${JOB_NAME}' (${BUILD_NUMBER}) is waiting for input",
    body: "Please go to ${BUILD_URL} and verify the build"

2.脚本

env.MYTOOL_VERSION = '1.33'
node {
  sh '/usr/local/mytool-$MYTOOL_VERSION/bin/start'
}

http://162.62.53.204/jenkins/pipeline-syntax/globals#env

相关文章:

  • 2021-08-11
  • 2021-09-09
  • 2021-04-24
  • 2021-10-06
  • 2021-11-08
猜你喜欢
  • 2021-06-23
  • 2021-07-31
  • 2021-10-10
  • 2021-08-13
  • 2021-12-13
  • 2022-01-11
相关资源
相似解决方案