0% found this document useful (0 votes)
10 views3 pages

Section 9 - Jenkins&Email

This document provides a comprehensive guide on integrating Jenkins with email notifications using AWS SES and Gmail. It outlines the installation of the Mailer plugin, configuration steps for both AWS SES and Gmail, and how to set up job notifications in Jenkins. Additionally, it includes best practices and troubleshooting tips to ensure effective email delivery and security considerations.

Uploaded by

Sachin Sharma
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views3 pages

Section 9 - Jenkins&Email

This document provides a comprehensive guide on integrating Jenkins with email notifications using AWS SES and Gmail. It outlines the installation of the Mailer plugin, configuration steps for both AWS SES and Gmail, and how to set up job notifications in Jenkins. Additionally, it includes best practices and troubleshooting tips to ensure effective email delivery and security considerations.

Uploaded by

Sachin Sharma
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Detailed Notes: Jenkins Email

Integration Setup and


Configuration
Lecture 1: Introduction

In this section we’ll learn how to integrate Jenkins with Email using AWS
SES & GMail.

Having notifications via Email is quite useful, because if any Job fails, then
Jenkins is going to notify you.

Lecture 2: Mail Plugin Installation


Before setting up email notifications, you need to ensure the Mailer plugin is
installed in Jenkins. This plugin typically comes with the “suggested plugins”
package during initial Jenkins setup. If not pre-installed, you can add it
through these steps:

1. Navigate to Manage Jenkins → Manage Plugins


2. Check the “Installed” section for the Mailer plugin
3. If not found, go to “Available” plugins and install the Mailer plugin

Lecture 3: AWS SES Integration


Amazon Simple Email Service provides a reliable way to send email
notifications from Jenkins. The setup process involves:

Domain/Email Verification in AWS

First, verify your email address or domain in AWS SES: 1. Access AWS SES
through the Services tab 2. Choose “Verify a new email address” 3. Enter
your email address 4. Click the verification link received in your email

Jenkins Configuration

Configure Jenkins to use AWS SES: 1. Go to Manage Jenkins → Configure


System 2. Locate the Email Notification section 3. Configure SMTP settings:
- Enter the AWS SMTP server address - Enable SMTP authentication -
Create and enter AWS SMTP credentials - Enable SSL - Use port 465 - Set
reply-to address 4. Configure Jenkins URL and System Admin email 5. Test
the configuration by sending a test email

Note: If test emails aren’t appearing in your inbox, check your spam folder.
Gmail often filters these messages initially.
Lecture 4: Gmail Integration
For teams without AWS access, Gmail integration offers an alternative
approach:

Gmail Configuration

1. Use smtp.gmail.com as the SMTP server


2. Enable “Less secure app access” in Google Account settings
◦ Navigate to Google Account settings
◦ Find the “Less secure app access” setting
◦ Toggle it to “On”

Jenkins Gmail Settings

1. Configure System settings:


◦ SMTP Server: smtp.gmail.com
◦ Enable SMTP Authentication
◦ Username: Your Gmail address
◦ Password: Your Gmail password
◦ Enable SSL
◦ Port: 465
2. Test the configuration

Lecture 5: Job Notification Setup


After configuring email integration, you can add notifications to specific
Jenkins jobs:

Configuration Steps

1. Open the job configuration


2. Scroll to Post-build Actions
3. Add Email Notification
4. Configure notification triggers:
◦ Enable “Send email for every unstable build”
◦ Enable “Send emails to individuals who broke the build”
5. Add recipient email addresses

Notification Behavior

The system will send notifications for: - Build failures (including detailed
error logs) - Recovery from failure states - Note: Successful builds after
recovery don’t trigger notifications

Best Practices and Troubleshooting


1. Port Accessibility
◦ Ensure port 465 is accessible from your network
◦ Check for ISP or corporate firewall restrictions
2. Email Delivery
◦ Monitor spam folders initially
◦ Mark Jenkins emails as “Not Spam” to improve future delivery
3. Security Considerations
◦ When using Gmail, be aware of the security implications of
enabling less secure app access
◦ Consider using AWS SES for production environments

This email notification system helps teams maintain awareness of their build
processes and quickly respond to failures, making it an essential part of a
robust CI/CD pipeline.

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy