0
ビルド後にいくつかの変数を電子メールテンプレートに渡す必要があります。私はそのために環境ブロックを使用しています(それらのうちのいくつかもスクリプトで作成されています)。 これは可能ですか?電子メールテンプレート内のJenkins宣言的パイプライン環境ブロック変数
environment {
SUBSCRIPTION = credentials('subscription')
CERT = credentials('cert')
}
post {
always {
emailext attachLog: true,
body: '''${SCRIPT,template="email.template"}''',
compressLog: true,
mimeType: 'text/html',
subject: "SUCCESS: ${env.JOB_NAME} [${env.BUILD_NUMBER}]",
to: '[email protected]'
}
}