added manifests, tweaked code to load manifests and find template