def __init__(self, configuration=None, assembly=None): self.assembly = assembly or Assembly.current() self.components = {} self.configuration = {} self.parameters = {} if configuration: self.configure(configuration)
def __init__(self, configuration=None, assembly=None): self.assembly = assembly or Assembly.current() self.components = {} self.configuration = {} self.parameters = {} self.services = {} if configuration: self.configure(configuration)
def __init__(self, sources): self.context = {} for source in sources or []: content = get_package_data(source) self.context.update(json.loads(content)) if 'meshconf' not in self.context: mesh_bundles = {} for k, v in Assembly.current().configuration.iteritems(): if k.startswith('mesh-proxy'): mesh_bundles[k[11:]] = v['path'] self.context['meshconf'] = MESHCONF_SCRIPT % json.dumps(mesh_bundles)
def assembly(self): return Assembly.current()