diff --git a/sdk/python/kfp/v2/components/types/artifact_types.py b/sdk/python/kfp/v2/components/types/artifact_types.py index d3f027f275a..6d3235bb18f 100644 --- a/sdk/python/kfp/v2/components/types/artifact_types.py +++ b/sdk/python/kfp/v2/components/types/artifact_types.py @@ -17,11 +17,12 @@ """ import os +from pathlib import Path from typing import Dict, Generic, List, Optional, Type, TypeVar, Union _GCS_LOCAL_MOUNT_PREFIX = '/gcs/' -_MINIO_LOCAL_MOUNT_PREFIX = '/minio/' -_S3_LOCAL_MOUNT_PREFIX = '/s3/' +_MINIO_LOCAL_MOUNT_PREFIX = '/var/run/kfp/artifact/minio/' +_S3_LOCAL_MOUNT_PREFIX = '/var/run/kfp/artifact/s3/' class Artifact(object): diff --git a/v2/component/launcher.go b/v2/component/launcher.go index 23fa18e9b65..79bc2b9afe8 100644 --- a/v2/component/launcher.go +++ b/v2/component/launcher.go @@ -655,10 +655,10 @@ func localPathForURI(uri string) (string, error) { return "/gcs/" + strings.TrimPrefix(uri, "gs://"), nil } if strings.HasPrefix(uri, "minio://") { - return "/minio/" + strings.TrimPrefix(uri, "minio://"), nil + return "/var/run/kfp/artifact/minio/" + strings.TrimPrefix(uri, "minio://"), nil } if strings.HasPrefix(uri, "s3://") { - return "/s3/" + strings.TrimPrefix(uri, "s3://"), nil + return "/var/run/kfp/artifact/s3/" + strings.TrimPrefix(uri, "s3://"), nil } return "", fmt.Errorf("failed to generate local path for URI %s: unsupported storage scheme", uri) }