Deploy from Github to Heroku with Hubot
Shell CoffeeScript
Switch branches/tags
Nothing to show
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.

Deploy from Github to Heroku with Hubot

NOTE WARNING DANGER ETC: You have to give heroku (via environment variables) your public and private github deploy key for the repository you're deploying. Make sure you understand that this means that heroku (themselves, or if their data is stolen) could access your github repo. OK? Proceed!


1. Copy

Copy the file to the root of your hubot. Copy to your scripts folder in your hubot.

2. Auth

Generate a key with ssh-keygen. Dont set a passphrase.

Upload it to github under your project's Deploy Key field.

We'll call this my-github-deploy-ssh-key from now on.

Send the public key to heroku:

heroku keys:add

3. Config

Export the following config vars to heroku:

GITHUB_KEY="`cat my-github-deploy-ssh-key`"

4. Deploy and Use

Commit the script changes to your hubot and push him to heroku. Then, in campfire:

hubot deploy