rcbops-qa/monster — pull request #209 by jcourtois (2014-06-19 18:41:42+00:00)
Title: adding a webserver to serve as an HTTP API

Instructions:
From within a suitable virtualenv, run ```python monster-api/pyramid/hello_deployment.py```. This will start the server on http://0.0.0.0:8080.

Currently, the only route that is defined supports post requests to
```
http://0.0.0.0:8080/rpcs/deployment/{name}
```

Hit the url with

```
curl http://127.0.0.1:8080/rpcs/deployment/my-deployment -d '{ "dry": false, "secret": "secret.yaml", "orchestrator": "chef", "name": "my-private-cloud", "template": "ubuntu-neutron-lite", "branch": "4.2.2", "destroy_on_failure": true, "provisioner": "rackspace", "config": "pubcloud-neutron.yaml", "log": null}'
```

This will initiate a build that's the equivalent of the command:
```
monster build rpcs my-deployment -c pubcloud-neutron.yaml -t ubuntu-neutron-lite -o chef -p rackspace -b 4.2.2 --destroy-on-failure
```