This is a Slack Bot to engage users of a given Slack channel into random discussion. It picks a random user out of the Slack team members and mentions him in a given channel with a random message.
Basically, you need to have Docker Toolbox installed
In order to have the bot running you need to create a Slack Bot. Once you have one you will be able to obtain a Slack API Token. Create a local set of parameters by copying the parameters file:
cp app/config/parameters.yml.dist app/config/parameters.yml
And put your token value there
In the project root directory run the following command:
docker-compose up -d
This command will build web
Docker image and run it a container with that image.
You can log into the container by typing:
docker-compose run web bash
Now you wil be signed into the container and in the project root directory.
In order to install the required dependencies, while in the container type:
composer install -n
To test the bot, while inside the container, run the command:
php app/console poke:user bot-sandbox --test
This will post the message into the #bot-sandbox
channel and only mentioning the test users
In order to run the real bot run
php app/console poke:user xhq
This will pick a random user and mention him on #xhq
channel
In order to run tests pleas type inside the container:
./bin/phpspec run
Maintained by the developers at x-team | developer blog