def options(self, name, metadata=None): """Get plugin/block options.""" group = Container.group() base = copy.deepcopy(Container.config().get(name, {})) override = group.run(name, metadata) if override is None: return base if override == {}: return {} return self.merge(base, override)
def reporter_list(): """List available reporters.""" empty = True print("CloudSelect reporters:") for reporter in sorted( Container.config().get("plugin", {}).get("report", {}).keys(), ): empty = False print("- {}".format(reporter)) if empty: print("- NO REPORTERS -")
def config(): """Return group configuration.""" return Container.config().get("group", {})
def config(): """Return discovery configuration.""" return Container.config().get("discovery", {})
def config(): """Return selector configuration.""" return Container.config().get("option", {})