I'm trying to implement puppet /etc/hosts handling using hiera as data
source, but my current implementation requires data duplication
because I could pass only array of strings as $name to host resource.

Is there any way to avoid such data duplication?
Or maybe it is possible to use templates but keep ability to have local modifications
to /etc/hosts file?