theforeman/foreman — pull request #1551 by domcleal (2014-07-01 08:50:34+00:00)
Title: fixes #6342 - ignore empty hashes inside cr_attrs when using compute profile

This problem's a little tricky, but I *think* it's the right thing to do. Feedback welcome.

If you're creating a host with a host group that has a compute profile, supplying compute_attributes isn't required. However if you're creating a host without a profile, you need to supply volume_attributes etc so the VM can be created (these params are expected by the CR models). Hammer always supplies them, but it doesn't know if a compute profile will be used or not, so I think it's best if we ignore empty sub-params and use the compute profile.