sitePp.add("$extlookup_datadir='/etc/puppet/manifests/extdata'");
sitePp.add("$extlookup_precedence = ['common']");
sitePp.add("node default {");
for (String role : roles) {
String manifestAttribPrefix = role.replaceAll(":+", ".");
Configuration manifestProps = new PropertiesConfiguration();
for (@SuppressWarnings("unchecked")
Iterator<String> it = config.getKeys(manifestAttribPrefix); it.hasNext();) {
String key = it.next();
manifestProps.setProperty(key, config.getProperty(key));
}
Manifest roleManifest = getManifestForClusterSpecAndRole(role, manifestProps);
if (isHiera) {
sitePp.add("include " + roleManifest.getName());
confHiera.add(roleManifest.getHiera());