merge data

Matthew Williams mgwilliams at gmail.com
Thu Oct 10 18:45:13 CEST 2013


This is a conversation that was started in a private email exchange. Per
Martin Krafft's suggestion, I'm moving it to the list.


I said:

>..it would be very convenient if reclass could be fed in starting data,
>e.g., the existing pillar data. This would allow reclass to be run as
>the final module, doing variable interpolation of prior pillar data.

Martin F. Krafft answered:

> Yes, this is even a TODO item, IIRC.
>
> It shouldn't be hard to implement. First, it needs to be decided
> whether the data should be integrated into the dict top-class (and
> thus be overrideable by yaml_fs data), or added to the dict under
> a subkey, e.g. __pillar__. I suggest the latter.

Putting it in __pillar__ would be a bit strange for the end user using the
data in, say, a jinja template: {{ pillar.__pillar__.foo }}. What would be
the disadvantages of making it overridable?

> Then, it needs to be walked once to identify those keys that contain
> references.

So you could use reclass style references within the data provided to
reclass? That would be pretty neat.

> Also, we must decide what to do wrt. Ansible and Puppet and the
> others, where the data are currently not made available.

Is there anything to do? The storage engine(s) could support the feature,
but the connectors could use or not use the feature as appropriate.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pantsfullofunix.net/pipermail/reclass/attachments/20131010/b0230fff/attachment.html>


More information about the reclass mailing list