-
Notifications
You must be signed in to change notification settings - Fork 3
Setup
In order to be used, Slack is requiring https url on its new Event API. It doesn't allow unstrusted SSL certificate (auto generated one). You can claim free certificates from Let's Encrypt or Start SSL.
First of all, ensure you're using the latest composer and SeAT version. We assume you will run all command with the
SeAT user
. This is mandatory. In the following line, you'll seedomain
in some url. You must replace this by your domain or slack access path.
- go on Slack Application
- clic on
Create New App
- on left side, clic on
OAuth & Permissions
and puthttps://domain/slackbot/oauth/callback
and save changes.
- put your SeAT instance offline by running
php artisan down
- including slackbot into SeAT with
composer require warlof/slackbot
- add the plugin to your SeAT instance by editing the file in
config/app.php
and append this lineWarlof\Seat\Slackbot\SlackbotServiceProvider::class
after https://github.com/eveseat/seat/blob/2.0.0/config/app.php#L185-L187
/*
* Package Service Providers...
*/
- publish the newly installed package with
php artisan vendor:publish --force
- update your database with
php artisan migrate
- restart supervisor using
sudo service supervisor restart
in order to load new codes - back your SeAT instance online with
php artisan up
- sign to your instance with a superuser and go into
Slackbot > Slackbot Settings
in order to setup the plugin - fill the fields
Slack Client ID
,Slack Client Secret
andSlack Verification Token
- hit the
Update
button
- First of all, you need to setup
Slack Client ID
,Slack Client Secret
andSlack Verification Token
intoSlackbot > Slackbot Settings
, fill the field and hitupdate
button - If needed, authenticate yourself using Slack Team credentials and confirm the team you want to bind with SeAT.
- On success and back to SeAT, click both on
Update Slack channels and groups
andUpdate Slack users
- Edit your slack permission going on
Slackbot > Slack Access Management
- back on your Slack created application information page
- on left side, clic on
Event Subscriptions
and puthttps://domain/slackbot/event/callback
(wait for check -Verified
) - into
Team Events
section, add following event :
- channel_archive
- channel_created
- channel_deleted
- channel_rename
- channel_unarchive
- group_archive
- group_close
- group_open
- group_rename
- group_unarchive
- message.channels (used in order to track channel join or leave events)
- message.groups (used in order to track group join or leave events)
- hit
Save Changes
at the bottom
When everything is correctly setup, go on your SeAT instance on Configuration > Schedule
and ensure that slack:update
is in the list. If not, you can add it with every five minutes
rule.
If you're on an existing Slack, go into Slackbot
> Slackbot Settings
from the sidebar and hit the Update Slack Channels and groups
button. This will pull all known private and public channels.
- Back to your SeAT instance
- Go into
Slackbot
>Slack Access Management
from the sidebar - Fill the
Quick create
form according to your needs
The table available on the right allow you to see the detail of applied permission foreach categories :
- public : everybody, without affiliation of any kind
- user : specific SeAT user
- role : all user attached to specific SeAT role
- corporation : all user which have at least one character in a specific corporation
- title : all user which own a specific title in a corporation
- alliance : all user which have at least one character in a specific alliance (this require
eve:eve-update
command to be run at least once)