Jenkins Email-ext: Attach Build Log not working
Asked Answered
D

2

1

I'm trying to use Email-ext (Version 2.27.1) with Jenkins (Version 1.508) to send an email when a build fails, to the committers who had worked on the project since the last success.

I'd like to also attach the build log to the email, and I see and check the "Attach Build Log" button, but whenever I click Save or Apply, and go back in to the configuration, the button is unchecked again. What's going on and how can I fix this?

Jenkins "Attach Build Log" Settings

Displeasure answered 4/4, 2013 at 14:2 Comment(0)
D
2

This was a bug in email-ext 2.27.1 and is fixed in 2.28 (Released today, if you'd believe it.)

See Version History Here

Displeasure answered 5/4, 2013 at 16:41 Comment(0)
A
0

We are probably using a bit older version of the email-ext on our system, so it doesn't have this option available.

Alternatively you can use the following variable in addition to the default content of the message: $BUILD_LOG

This will not display the log content correctly if you are using html as content type (doesn't show new lines correctly) but it will work fine with the Text content type.

For the html you can have a customizable content using Jelly Scripts. There are some default examples that will display at least the final part of the Build Log.

Abound answered 5/4, 2013 at 13:9 Comment(1)
This was a bug in 2.27.1, and has been fixed in 2.28 which was released today.Displeasure

© 2022 - 2024 — McMap. All rights reserved.