This version is compatible with:
- Puppet Enterprise >=2015.2.0 < 2016.2.0
Start using this module
- Setup - The basics of getting started with skel
- Limitations - OS compatibility, etc.
- Development - Guide for contributing to the module
This module configures the PE Bot for Slack.
Classify your Master with the pe_slack_bot. You'll need at least to make your $slack_api_key available as a variable. You can get it by clicking the Add to Slack Button below (it will call back to a web page showing your API Key for the bot).
In order to do orchestration tasks, you'll need to configure the right permissions in "Access Control", in the PE Console, and a token in /opt/puppetlabs/server/data/puppetserver/.puppetlabs/token.
The following animations briefly illustrate how to do it, but for more information please refer to the Puppet Enteprise documentation
First /invite puppet to your channel. Check the documentation on how to use the bot, or try on of the following:
- puppet status $certname
- puppet job list
- puppet job show $showid
- puppet app list
- puppet job run
The bot is designed to run with the Puppet Enterprise Ruby (in order not to affect neither Puppet nor the system ruby). It does however install a number of gems:
It also creates a configuration file in the Puppet configuration directory (/etc/puppetlabs/puppet by default), and a systemd service to run the bot at start time (after the start of pe-orchestration-services). Finally in clones the master (stable) branch of the bot from https://github.com/ncorrare/pe-slack-bot in /opt/pe-slack-bot. You can specify a $version variable upon classification to fix it to a specific tag.
This bot has only been tested in Centos 7, but it should work with most of the certified PE Master operating systems (that use systemd). I'll try to extend the testing to other platforms, and possibly add backwards compatibility to init.d.
Send a PR to either the Puppet module or the bot. I haven't had time to write unit tests yet, but they'll be added shortly. Travis is used for CI so every PR is automatically tested. Upon merging, a new release of the module will be pushed to the forge.