cloudfoundry/bosh — pull request #537 by goonzoid (2014-03-02 17:03:14+00:00)
Title: Instance Tainting

*Note: this pull request is __not complete__ and is being pushed now to gain feedback.*

BOSH is designed to be a system that performs declarative deployments that do not require additional work performed on them after they have been deployed. However, when diagnosing problems it is often useful to SSH into a job to have a look around. This, unfortunately, leaves the jobs in a *tainted* state as we do not know what changes may have been made to them.

This change adds the concept of a job instance becoming tainted when it is SSH'd into via the `bosh ssh` command and then adds the `bosh untaint ` command to recreate all of the tainted instances in a deployment. This could be used after a problem has been diagnosed to make sure that there are no snowflake jobs running in the cluster.

- [x] Add CLI Command
- [x] Add director endpoint to untaint a deployment
- [ ] Job instances should become tainted when someone SSHs into them
- [ ] Job instances should become untainted when they are recreated
- [ ] The user should be able to see which job instances are tainted in the CLI
- [ ] Add BATs test for untainting

P.S. We wrote much of this code whilst pairing on a plane, via tmux, 30,000ft over Greenland!

![plane_pairing](https://f.cloud.github.com/assets/1255755/2304645/77312650-a22c-11e3-9531-ebc5e1b0abc8.jpg)

Will & Chris