Skip to content

Ghost-Programmer/ifttt-build-notifier-plugin

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

55 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ifttt-build-notifier

A Simple Jenkins Build Status Notifier for IFTTT Maker Channel Trigger

Posts the build status to IFTTT Maker Channel to trigger actions with all other Channels available on IFTTT. For example notify build status via a tweet or add trello card or Light-up a IoT connected device.

Create an installable artifact:

  1. git clone https://github.com/upgundecha/ifttt-build-notifier.git
  2. cd ifttt-build-notifier
  3. mvn clean install
  4. Install Plugin via Manage Jenkins > Plugins > Advanced > Upload ./target/ifttt-build-notifier.hpi
  5. Restart Jenkins ([$JENKINS_URL]/restart)

Let's setup a notification trigger with following steps. This will send a direct twitter message when a build job is completed:

Login to https://ifttt.com and perform the following steps:

  1. Create a new Recipe
  2. Click on this part
  3. Enter or select Maker Channel in Choose Trigger Channel
  4. Select Receive a Web Request in Choose a Trigger
  5. Enter an Event name (for example build_notification)
  6. Click on Create Trigger button
  7. Next, click on that part
  8. Enter or select Twitter in Choose Action Channel
  9. Select Send a direct message to yourself in Choose an Actin
  10. Enter following message in Message field in Complete Action Fields
Jenkins Build Status for Project: {{Value1}}, Build Number:{{Value2}}, Status: {{Value3}} 

Note: IFTTT Maker Channel Receive a Web Request trigger accepts three values and plugin sends Project Name as Value1, Build Number as Value2 and Status as Value3

  1. Finally click on Create Action button
  2. Give a name to newly created recipe
  3. Click on Create Recipe button to create the recipe
  4. Now, navigate to https://ifttt.com/maker
  5. Copy the Key from Your key is: section

You can also use template recipe from here https://ifttt.com/recipes/336376-send-a-direct-tweet-when-jenkins-build-is-completed (see more recipes below)

Back in Jenkins setup a project to send build notifications:

  1. Configure a Job or Project for which you want to enable IFTTT trigger
  2. Add IFTTT Build Notifier action from Add Post Build Action list
  3. Enter Event Name specified in Step#4 above (for example build_notification)
  4. Enter Key copied from Step#14 above
  5. Save the configuration
  6. That's it

Now whenever a build is triggered and completed, you will see a Twitter message with build status

More Recipe Templates:

About

Simple Jenkins Build Status Notifier for IFTTT Maker Channel Trigger

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Java 97.6%
  • HTML 2.4%