crowbar/barclamp-crowbar — pull request #635 by VictorLowther (2013-07-27 02:45:20+00:00)
Title: Make more progress in having the admin node bootstrap itself. [1/2]

This pull request series has a few critical features for CB 2.0:

* Full inbound and outbound data paths implemented for the script
jig.
* Standardized on_STATE callbacks for node role transitions. These
are implemented as autodiscovered mixins for specific role objects,
and the node role state machine will call the appropriate ones as
part of state transition.
* The chef-client role configures itself based on attributes that
the chef-server role sets, and uses an on_todo callback to generate
a chef client key for a node if needed.
* The data and wall fields of the noderole and deploymentrole
objects have had their getters and setters wrapped to enforce that
they are valid JSON at all times. The access rule is that the
framework owns the data field, and that the jig owns the
wall. data and wall may be replaced by specialized tables if
needed.
* noderole knows how to coalesce all of the information in all of
the data and wall fields of all of any given noderole's parents in
order to come up with the combined set of all attributes that the
noderole should consider to be relavent. The approach it uses is
rather simplistic for now, but should suffice to start getting
Real Work done.

.../app/models/barclamp_crowbar/jig.rb | 114 +++++++++++++++++---
crowbar_framework/app/models/deployment_role.rb | 31 ++++--
crowbar_framework/app/models/node_role.rb | 84 ++++++++++++---
crowbar_framework/app/models/role.rb | 3 -
script/roles/crowbar/001_ping.sh | 3 +-
script/runner | 24 +++++
6 files changed, 217 insertions(+), 42 deletions(-)

Crowbar-Pull-ID: 07cd2da2c693f3f87b4152996b7da62491f566ac

Crowbar-Release: development