GoonBot is a Node.js application which forwards Jabber messages from the Goonswarm's directorbot (pings) to a Slack.
- Create a slack here
- Create a slack bot
- Record the slack bot's API Token
- In your slack add a few channels:
- One to post every message that comes through directorbot
- One for GoonBot to post in if an error occurs/it goes offline
- Invite the slack bot to all channels that you just created.
- Install node.js
- Download this project to a folder
- In that folder run
npm install
- Rename config/default.json.example to config/default.json
- In the "jabber" section fill in "user" and "password" with your login info from ESA
- In the "slack" section fill in "token" with the API token you copied in Part 1 Step 3.
- In the "slack.channels" section fill in "all" with the name of the channel you want all pings to go to.
- Again in the "slack.channels" section fill in "status" with the name of the channel you want the bot's status messages to go to.
- Run the app with npm start.
You probably want this to run as a service so I recommend using Forever
- Run
[sudo] npm install forever -g
- In the application folder run
forever start forever.json
You may want to have a channel specifically for fleet pings, filtered channels provide that option.
- Create a slack channel
- Invite the slack bot to that channel.
- Create a entry in the default.json "slack.channels.filters" section, a couple examples are provided.
- The "channel" is the name of the channel in slack, "filter" is a regular expression to check against the ping broadcasted.