PHP > MantisBT-Slack
MantisBT plugin to send bug updates to Slack
MantisBT-Slack
A MantisBT plugin to send bug updates to Slack, Mattermost and Discord channels.
Setup
The
masterbranch requires Mantis 2.x, while themaster-1.2.xbranch works for Mantis 1.2.x.Extract this repo to your Mantis folder/plugins/Slack.
On the Slack side, add a new "Incoming Webhooks" integration and note the URL that Slack generates for you.
On the MantisBT side, access the plugin's configuration page and fill in your Slack webhook URL.
You can map your MantisBT projects to Slack channels by setting the plugin_Slack_channels option in Mantis. Follow the instructions on the plugin's configuration page to get there. Make sure the plugin_Slack_channels configuration option is set to "All Users", with type "complex". Example value for this setting:
array ( 'My First Mantis Project' => '#general', 'My Second Mantis Project' => '#second-project' )You can specify which bug fields appear in the Slack notifications. Edit the plugin_Slack_columns configuration option for this purpose. Follow the instructions on the plugin configuration page.
For Discord, you need to append
/slackso that Discord handles this as a Slack-compatible webhook. More info here.
Development
You can run a local development environment using Docker Compose:
docker-compose build && docker-compose up- Open http://localhost:8080/admin/install.php and install the database (using Admin credentials
root/root) - Login to Mantis using
administrator/root - Enable Slack plugin at http://localhost:8080/manage_plugin_page.php