opscode/chef — pull request #662 by lxndrp (2013-02-27 16:19:08+00:00)
Title: Additional option for knife bootstrap to accept JSON files for firstboot

Folks,

we are making heavy use of the -j option in knife bootstrap and found it somewhat cumbersome to keep `.sh` scripts around with inline JSON.

Mainly for our own convenience, I added a new configuration option to the `bootstrap` plugin to accept a JSON file instead of inline JSON attributes. Accordingly, I modified the `BootstrapContext` class to honor the new parameter.

Precedence is _JSON attributes_ (`-j|--json-attributes`) > _JSON file_ (`-J|--json-file`); that is, if both are supplied, attributes will win and the file is not considered at all.

Hope this patch is useful for you as well.

Cheers,
Alexander