def init_metadata(ctx, user_defined_path): """Load and initialize job metadata.""" config = ctx.obj[CONFIG] meta_path = user_defined_path or config.metadata_path() if not meta_path: raise ConfigError("Job metadata file path not provided.") if not os.path.exists(meta_path): raise ConfigError(f"Job metadata file not found: {meta_path}") metadata_data = load_yaml(meta_path) ctx.obj[METADATA] = metadata_data return metadata_data
def init_prov_config(path): """Load and initialize provisioning configuration.""" config_data = load_yaml(path) config = ProvisioningConfig(config_data) return config
def init_metadata(path): """Load and initialize job metadata.""" metadata_data = load_yaml(path) return metadata_data