How to Install and Configure Email Notifications in Jenkins
In this article, we are going to learn one of the most and interesting
topics on how to configure email notifications in Jenkins.
To Setup Email notifications in Jenkins, we need to follow the below
step. Please Note this configuration we need to do
only once.
1)
Login into Jenkins.
2) Navigate to Manage Jenkinsร Manage Plugin, under the
available section search for Email-ext plugin and install it.
3)
Now navigate back to Jenkins home page and Navigate Manage Jenkins ร Configure System.
4)
Search for Email notification section and click on Advanced.
5)
Enter details as below for Gmail notifications.
·
SMTP server name : smtp.gmail.com
·
User name: youruserid@gmail.com
·
Password: YourPassword
·
Use SSL : Checked
·
SMTP Port: 456
6)
To validate the email configuration click on “Test Configuration
by sending an email” by providing your email id.
7)
Click on apply and save option present at the bottom of the
screen.
Now to actually send an email notification through Jenkins we need
to follow the below steps:
1)
Login into Jenkins.
2)
Create/Modify the existing Jenkins Job.
3) Click the Add Post Build Action dropdown and select value
Editable email notifications.
4)
Complete the editable email notification section.
5) Click on Advanced Setting button in the editable email notification
section
6)
Click on Add trigger option and select the value as “Always”
7)
Click on Save Button and build your Jenkins job.
8)
We would be able to see Jenkins's email notification in our mailbox.