A minimal, extendable bot for Mattermost written in Python and inspired by Slack's Stuart.
The easiest way to install is using docker. You will need to create and mount
a config.py file for which an example template is in the stewie directory.
$ curl https://raw.githubusercontent.com/nnewman/stewie/master/stewie/config.template.py > config.py
$ vim config.py
$ docker pull nnewman/stewie:latest
$ docker run -t -v "<current path>y:/opt/stewie" -p "8043:8043" nnewman/stewie:latest sh -c "gunicorn -b 0.0.0.0:8043 stewie.server:app"
Add a new slash command for Stewie using Mattermost. Some debugging will be necessary as you will need your team ID, which Mattermost doesn't seem to expose in the UI....
After installing, use /stewie help to see a list of available commands.
Sometimes we may want to extend Stewie without getting in the way of core functionality. Following the example
in stewie.py, you can write extension functions in a file within the extensions folder, and then add a config
key called EXTENSIONS which references your new module. Stewie will pick functions from your extensions first,
so it's possible, and encouraged, to use this mechanism to override core functionality. The hope here is that
everyone can make Stewie their own, without the need to fork him. See extensions.py.example for more.
I'd love to add more capabilities to Stewie, and would appreciate any feedback and/or Pull Requests which can add to him.
My requirements are, however, that any additions fit into the current design scheme and my requirements:
stewie.py file in similar format to the current schemeplugins folder for importconfig.template.py and imported from a config file, to be created by the userContent type
Image
Digest
Size
45.3 MB
Last updated
about 10 years ago
docker pull nnewman/stewie