How to retrieve value of base64 string stored in a variable to Jenkins Extended E-mail Notification plugin -
i saving buildtimegraph image (png) file in jenkins. wanted embed image , send via mail using extended e-mail notification plugin. build triggered via ant scripts.
when using "certutil" in cmd , converting base64. getting 2 statements says -----begin certificate----- , -----end certificate----- in base64 string. use filterchain > tokenfilter > replacestring ant remove these lines string , save them variable.
does know how variable can used in img src tag ? have attempted many combinations but, not worked me. looks like. value of $image1 can seen in jenkins log when echo them using ant. but, when using them in extended e-mail notification plugin. wont print.
<img alt="image 1" src="data:image/png;base64, $image1" />
thanks.
to reference environment variable in email-ext plugin, need use
${env, var="image1"}
keep in mind if environment variable created in ant build step, not exist in post-build actions (unless ant script creates permanent system environment variable)
you need have ant script write variable file, , use envinject plugin read file , inject variable. available regular environment variable email-ext, used syntax provided
Comments
Post a Comment