All Projects → mdg-iitr → bot

mdg-iitr / bot

Licence: other
Slack bot (bro) for Mobile Development Group, IITR.

Programming Languages

coffeescript
4710 projects
Dockerfile
14818 projects

Projects that are alternatives of or similar to bot

hubot-bearychat
BearyChat Adapter for Hubot
Stars: ✭ 99 (+661.54%)
Mutual labels:  hubot
hubot-suggest
Suggest hubot commands when not found
Stars: ✭ 29 (+123.08%)
Mutual labels:  hubot
docker-hubot
Docker container for running hubot in a container.
Stars: ✭ 17 (+30.77%)
Mutual labels:  hubot
mattermost-client
Mattermost client using websockets
Stars: ✭ 59 (+353.85%)
Mutual labels:  hubot
hubot-markov
Hubot watches all, and builds a markov model from everything you say.
Stars: ✭ 63 (+384.62%)
Mutual labels:  hubot
hubot-messenger-bot
🔌 A Hubot adapter for Facebook Messenger Platform (Bots) with zero external dependencies.
Stars: ✭ 44 (+238.46%)
Mutual labels:  hubot
hubot-seen
A hubot script that tracks when/where users were last seen.
Stars: ✭ 25 (+92.31%)
Mutual labels:  hubot
saihubot
💬 client side chatbot that works in the browser and command line
Stars: ✭ 15 (+15.38%)
Mutual labels:  hubot
hubot-typescript-boilerplate
ChatOps made easier
Stars: ✭ 20 (+53.85%)
Mutual labels:  hubot
hubot-code-review
A Hubot script for GitHub code review on Slack.
Stars: ✭ 38 (+192.31%)
Mutual labels:  hubot
hubot-alias
Action alias for hubot
Stars: ✭ 21 (+61.54%)
Mutual labels:  hubot
hackmit-hackbot
🤖 HackMIT's personal assistant!
Stars: ✭ 13 (+0%)
Mutual labels:  hubot
st2chatops
Packaging environment for building StackStorm chatops native packages
Stars: ✭ 26 (+100%)
Mutual labels:  hubot
hubot-broadlink-rm
A hubot script to learn and send IR hex codes with Broadlink RM
Stars: ✭ 24 (+84.62%)
Mutual labels:  hubot
hubot-zulip
No description or website provided.
Stars: ✭ 19 (+46.15%)
Mutual labels:  hubot
Huggies
Huggies is a plug and play automation tool for AWS Elastic Beanstalk
Stars: ✭ 13 (+0%)
Mutual labels:  hubot
hubot-ansible
A hubot script for launching ansible commands
Stars: ✭ 14 (+7.69%)
Mutual labels:  hubot
groupme-at-all
A Hubot chat bot to mention every user in a GroupMe channel all at once.
Stars: ✭ 94 (+623.08%)
Mutual labels:  hubot
hubot-group-alias
@mentions for groups using Hubot
Stars: ✭ 14 (+7.69%)
Mutual labels:  hubot
hubot-dingtalk
hubot-dingtalk:支持钉钉Outgoing
Stars: ✭ 29 (+123.08%)
Mutual labels:  hubot

Hubot

This is a version of GitHub's Campfire bot, hubot. He's pretty cool.

This version is designed to be deployed on Heroku. This README was generated for you by hubot to help get you started. Definitely update and improve to talk about your own instance, how to use and deploy, what functionality he has, etc!

Testing Hubot Locally

You can test your hubot by running the following.

% bin/hubot

You'll see some start up output about where your scripts come from and a prompt.

[Sun, 04 Dec 2011 18:41:11 GMT] INFO Loading adapter shell
[Sun, 04 Dec 2011 18:41:11 GMT] INFO Loading scripts from /home/tomb/Development/hubot/scripts
[Sun, 04 Dec 2011 18:41:11 GMT] INFO Loading scripts from /home/tomb/Development/hubot/src/scripts
Hubot>

Then you can interact with hubot by typing hubot help.

Hubot> hubot help

Hubot> animate me <query> - The same thing as `image me`, except adds a few
convert me <expression> to <units> - Convert expression to given units.
help - Displays all of the help commands that Hubot knows about.
...

Scripting

Take a look at the scripts in the ./scripts folder for examples. Delete any scripts you think are useless or boring. Add whatever functionality you want hubot to have. Read up on what you can do with hubot in the Scripting Guide.

Redis Persistence

If you are going to use the redis-brain.coffee script from hubot-scripts (strongly suggested), you will need to add the Redis to Go addon on Heroku which requires a verified account or you can create an account at Redis to Go and manually set the REDISTOGO_URL variable.

% heroku config:set REDISTOGO_URL="..."

If you don't require any persistence feel free to remove the redis-brain.coffee from hubot-scripts.json and you don't need to worry about redis at all.

Adapters

Adapters are the interface to the service you want your hubot to run on. This can be something like Campfire or IRC. There are a number of third party adapters that the community have contributed. Check Hubot Adapters for the available ones.

If you would like to run a non-Campfire or shell adapter you will need to add the adapter package as a dependency to the package.json file in the dependencies section.

Once you've added the dependency and run npm install to install it you can then run hubot with the adapter.

% bin/hubot -a <adapter>

Where <adapter> is the name of your adapter without the hubot- prefix.

hubot-scripts

There will inevitably be functionality that everyone will want. Instead of adding it to hubot itself, you can submit pull requests to hubot-scripts.

To enable scripts from the hubot-scripts package, add the script name with extension as a double quoted string to the hubot-scripts.json file in this repo.

external-scripts

Tired of waiting for your script to be merged into hubot-scripts? Want to maintain the repository and package yourself? Then this added functionality maybe for you!

Hubot is now able to load scripts from third-party npm packages! To enable this functionality you can follow the following steps.

  1. Add the packages as dependencies into your package.json
  2. npm install to make sure those packages are installed

To enable third-party scripts that you've added you will need to add the package name as a double quoted string to the external-scripts.json file in this repo.

Deployment

% heroku create --stack cedar
% git push heroku master
% heroku ps:scale app=1

If your Heroku account has been verified you can run the following to enable and add the Redis to Go addon to your app.

% heroku addons:add redistogo:nano

If you run into any problems, checkout Heroku's docs.

You'll need to edit the Procfile to set the name of your hubot.

More detailed documentation can be found on the deploying hubot onto Heroku wiki page.

Deploying to UNIX or Windows

If you would like to deploy to either a UNIX operating system or Windows. Please check out the deploying hubot onto UNIX and deploying hubot onto Windows wiki pages.

Campfire Variables

If you are using the Campfire adapter you will need to set some environment variables. Refer to the documentation for other adapters and the configuraiton of those, links to the adapters can be found on Hubot Adapters.

Create a separate Campfire user for your bot and get their token from the web UI.

% heroku config:set HUBOT_CAMPFIRE_TOKEN="..."

Get the numeric IDs of the rooms you want the bot to join, comma delimited. If you want the bot to connect to https://mysubdomain.campfirenow.com/room/42 and https://mysubdomain.campfirenow.com/room/1024 then you'd add it like this:

% heroku config:set HUBOT_CAMPFIRE_ROOMS="42,1024"

Add the subdomain hubot should connect to. If you web URL looks like http://mysubdomain.campfirenow.com then you'd add it like this:

% heroku config:set HUBOT_CAMPFIRE_ACCOUNT="mysubdomain"

Restart the bot

You may want to get comfortable with heroku logs and heroku restart if you're having issues.


Installation using Docker

  • Build the image using docker build . -t bot:latest
  • Add the environment variables in a .env file
  • Create a container to run the image docker run -d --env-file .env --name bot_cont -p 127.0.0.1:<Port on host>:8080 bot

Development setup using Docker

You can use the dev_docker-compose.yml file to spin up containers with Redis services easily. Use this env variables for the same.

REDIS_URL=redis://redis:6379

Run this command to run the containers

$ docker-compose -f dev_docker-compose.yml up

To interact with hubot using shell,

$ docker exec -it mdg-bot bash
$ ./bin/hubot
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].