cleanweb-uk/cleanbot — pull request #1 by mrchrisadams (2012-07-31 23:39:45+00:00)
Title: Add an example config to run cleanbot on cloud foundry instead of heroku

After today, I figured I'd try running cleanbot on cloudfoundry instead of heroku.

Here's what I had to do:

First, I set the API endoint for `vmc`:

vmc target api.cloudfoundry.com

Then I set the login credentials

vmc login

After this, because cloudfoundry doesn't seem to let you set vars using `export` in bash scripts, you need to set them explicitly, like so:

vmc env cleanishbot
vmc env-add cleanishbot HUBOT_IRC_SERVER="irc.freenode.net"
vmc env-add cleanishbot HUBOT_IRC_ROOMS="##cleanweb"

Once you have this, you can then try pushing it

vmc push

The output should look a bit like this. the `Y` or `N` commands are my responses to the prompts when running the deploy for the first time.

Would you like to deploy from the current directory? [Yn]: Y
Application Name: cleanishbot
Detected a Standalone Application, is this correct? [Yn]: y
1: java
2: java7
3: node
4: node06
5: node08
6: ruby18
7: ruby19
Select Runtime: 5
Selected node08
Start Command: bin/hubot -a irc -n cleanishbot
Application Deployed URL [None]:
Memory reservation (128M, 256M, 512M, 1G, 2G) [64M]: 128
How many instances? [1]: 1
Create services to bind to 'cleanishbot'? [yN]: n
Would you like to save this configuration? [yN]: y
Manifest written to manifest.yml.
Creating Application: OK
Uploading Application:
Checking for available resources: OK
Packing application: OK
Uploading (10K): OK
Push Status: OK
Staging Application 'cleanishbot': OK
Starting Application 'cleanishbot': OK

And that seems to be it! It's up!