Follow these steps to integrate Jenkins with Rocket.Chat using the Rocket.Chat Notifier plugin:
Before setting up notifications, ensure you have already created a Jenkins job.
1. Install the Rocket.Chat Notifier plugin
Log in to your Jenkins dashboard
Navigate to Dashboard > Manage Jenkins > Plugins
In the Available plugins tab, search for Rocket.Chat Notifier and install it
2. Configure global Rocket.Chat Notifier settings
Navigate to Dashboard > Manage Jenkins > System
Scroll down to find the Global Rocket.Chat Notifier Settings and fill in the required fields:
Rocket.Chat Server URL: Enter your Rocket.Chat server URL
Login Username and Password: Provide the login credentials of the user who will post the notifications
Channel: Specify the channel(s) in Rocket.Chat where notifications should be sent
Save the configuration
3. Configure notifications for the Jenkins job
Open the Jenkins job you created earlier
Navigate to the Post-Build Actions section
Click Add Post-Build Action and select Rocket.Chat Notifications
Choose the types of notifications you want to receive, such as build success, failure, or other events
4. Receive notifications in Rocket.Chat
Once the integration is complete, changes to the connected GitHub repository of the Jenkins job will trigger notifications which will be sent to the specified Rocket.Chat channel(s) based on the events you selected.