Merge "Implemented mailing in generate cookiecutter pipeline"
diff --git a/generate-cookiecutter-products-auto.groovy b/generate-cookiecutter-products-auto.groovy
index 40a58c8..8eda759 100644
--- a/generate-cookiecutter-products-auto.groovy
+++ b/generate-cookiecutter-products-auto.groovy
@@ -138,8 +138,7 @@
sh(returnStatus: true, script: "tar -zcvf ${clusterName}.tar.gz -C ${modelEnv} .")
archiveArtifacts artifacts: "${clusterName}.tar.gz"
if(EMAIl_ADDRESS != null && EMAIL_ADDRESS){
- //TODO: mail
- def TODO= "todo"
+ emailext(to: EMAIL_ADDRESS, attachmentsPattern: '^${clusterName}\\.tar\\.gz\$', body: 'Mirantis Jenkins\n\nRequested reclass model ${clusterName} created and has been attached to this email.\nEnjoy!\n\nMirantis Inc.', subject: 'Your Salt model ${clusterName}')
}
}