- Notifications
You must be signed in to change notification settings - Fork4
orcaman/redibot
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
redibot
is a redis bot for Slack I hacked on the other day. Hopefully we could turn this into something useful.
Features:
- Pub-sub support: the neat thing about this is that you can basically start sending notifications into Slack from any of your servers via redis publishing. Subscribe to any channel from Slack and publish from any backend that has access to publish on redis.
- Collabarative: bring redis into the conversation! you can fetch, set, etc. from redis and discuss with your team mates.
redis-cli
in your Slack. No need to leave Slack in order to run redis commands.
In order to useredibot
, you need to run theredibot
server and setup a new bot on your slack account. SeeAdding a new bot to your slack below. Once installed, use theredis commands syntax same as you would useredis-cli
. A few examples:
Connect to a redis server instance:
@redibot connect my.redis.host.com:6379 MY REDIS PASSWORD
Set a value on redis:
orcaman [12:19 PM] @redibot INCR counterredibotBOT [12:19 PM] 1

You can also publish and subscribe! the neat thing about this is that you can basically start sending notifications from all your servers via redis publishing, without having to create a designated webhook on Slack.
@redibot subscribe my_channel@redibot publish my_channel hello there!---- output on slack -----my_channel: message: hello there!

- Browser over here:https://my.slack.com/services/new/bot
- Create "redibot" username (or any other name that suites you)
- Grab tha auth token - you need this to run the server
It's easiest to run the server using docker:
docker run -e "redibot_token=YOUR SLACK BOT TOKEN" orcaman/redibot
Otherwise you can build and run the binary (see development).
CD to the redibot directory, get the deps and go build:
go get github.com/garyburd/redigo/redisgo get github.com/gorilla/websocketgo build
To update the docker container after a new build:
docker build -t orcaman/redibot.