This message was deleted.
# bolt
s
This message was deleted.
y
what kind of data do you mean?
I’d say you can use inventory to set the target’s variables e.g.
Hiera usage is a bit specific with bolt plans..
though one can use interpolation to make a hierarchy too: https://www.puppet.com/docs/bolt/latest/hiera.html#interpolations-outside-apply-blocks
m
Fore example a group of nodes "prod" and "test" where I want to create a file at a path but the path is different for each group. Or any other kind of data that is different for single targets or target groups
Some data needs to be variable and I am wondering if there is some best practice on where to store that and how to access it
y
I’d try to combine inventory vars to set the environment e.g. and then use Hiera plan hierarchy based on the vars
m
Well yes I can McGyver something together but was thinking there must be something where I can lean onto 😄
y
you can even use another plan to enrich your targets via
set_vars()
or
add_facts()
m
But if not I'll just play around a bit
y
I guess there are not that many Bolt users who does some heavy-lifting.. that’s why it’s hard to speak about some best practices at the moment
but maybe @nlew can suggest something
m
Gotcha! I'm open to any suggestions 🙂 I guess I was just naive in thinking I can rely on the comfort of knowing I have a hiera backend for all my config data heh Also I'm just starting out with Bolt plans so I might not have the fundamentals down – even after reading the docs over and over
y
you still should be able to use plan hierarchy in Hiera.. just need to try and fail a bit with variable interpolations I believe
maybe it’s even possible to share some data with usual puppet.. but I didn’t tried