hubot-servicenow

0.3.0 • Public • Published

hubot-servicenow

hubot-servicenow is a chat bot built on the Hubot framework. It was initially generated by generator-hubot, and configured to be deployed on Heroku to get you up and running as quick as possible.

This README is intended to help get you started. Definitely update and improve to talk about your own instance, how to use and deploy, what functionality is available, etc!

Running hubot-servicenow Locally

You can test your hubot by running the following, however some plugins will not behave as expected unless the environment variables they rely upon have been set.

You can start hubot-servicenow locally by running:

% bin/hubot

You'll see some start up output and a prompt:

[Sat Feb 28 2015 12:38:27 GMT+0000 (GMT)] INFO Using default redis on localhost:6379

Configuration

A few scripts (including some installed by default) require environment variables to be set as a simple form of configuration.

Each script should have a commented header which contains a "Configuration" section that explains which values it requires to be placed in which variable. When you have lots of scripts installed this process can be quite labour intensive. The following shell command can be used as a stop gap until an easier way to do this has been implemented.

grep -o 'hubot-[a-z0-9_-]\+' external-scripts.json | \
  xargs -n1 -I {} sh -c 'sed -n "/^# Configuration/,/^#$/ s/^/{} /p" \
      $(find node_modules/{}/ -name "*.coffee")' | \
    awk -F '#' '{ printf "%-25s %s\n", $1, $2 }'

How to set environment variables will be specific to your operating system. Rather than recreate the various methods and best practices in achieving this, it's suggested that you search for a dedicated guide focused on your OS.

Adapters

Adapters are the interface to the service you want your hubot to run on, such as 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 with npm install --save 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.

Deployment

% heroku create --stack cedar
% git push heroku master

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.

Restart the bot

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

Readme

Keywords

none

Package Sidebar

Install

npm i hubot-servicenow

Weekly Downloads

6

Version

0.3.0

License

none

Last publish

Collaborators

  • anthonypjshaw