def load_template_ec2_requests()

in lib/muchos/config/ec2.py [0:0]


    def load_template_ec2_requests(self, template_dir):
        for json_path in glob.glob(os.path.join(template_dir, "*.json")):
            service = os.path.basename(json_path).rsplit(".", 1)[0]
            if service not in SERVICES:
                exit(
                    "ERROR - Template '{0}' has unrecognized option '{1}'. "
                    "Must be one of {2}".format(
                        self.cluster_template_d["id"], service, str(SERVICES)
                    )
                )
            with open(json_path, "r") as json_file:
                # load as string, so we can use string.Template
                # to inject config values
                self.cluster_template_d[service] = json_file.read()