Pullb0t
A bot for posting new Gitlab Merge requests to a Slack Webhook with automatic JIRA integration
Developed with ❤️ by CloudCall
Features
- Automatically detect JIRA ticket numbers in the branch name or commit message
- Post all new non-WIP merge requests to a given Slack Webhook URL
Setup
Environment Variables
The bot requires a few config options. Here's how to get them
JIRA Details
It is recommended you create a new "bot" user account and assign it global admin privileges (so it can view all boards)
JIRA_URL="company.atlassian.net" - Note the lack of the http/https!
JIRA_USERNAME="bot" - the JIRA username used to query the API
JIRA_PASSWORD="password" - the JIRA password for the above user
Slack
- Add the "Incoming Webhook" integration
- Add a new configuration - setup where the webhook messages will go, and the user they will be posted as
- Copy the "Webhook URL" on the page
Gitlab
GITLAB_URL="https://git.company.gitlab.com" - Just the URL for your git instance
Standard
- Clone the project -
$ git clone https://github.com/joshghent/pullb0t.git
- Copy of the
.env.example
file and fill in the details - Run
npm start
!
Docker
docker run -d --restart always \ --name pullb0t \
--env JIRA_URL="company.atlassian.net" \
--env JIRA_USERNAME="botuser" \
--env JIRA_PASSWORD="password" \
--env SLACK_WEBHOOK_URL="HOOK_URL" \
--env GITLAB_URL="GITLAB_URL" -p 1337:3000 joshghent/pullb0t:latest
Bugs
Please create a new issue here
License
MIT - CloudCall
Author
Josh Ghent on behalf of CloudCall