diff --git a/sdk/python/kfp/components/_components.py b/sdk/python/kfp/components/_components.py index 5fbe2320cac6..068756190966 100644 --- a/sdk/python/kfp/components/_components.py +++ b/sdk/python/kfp/components/_components.py @@ -190,7 +190,7 @@ def _load_component_spec_from_component_text(text) -> ComponentSpec: _inputs_dir = '/tmp/inputs' -_outputs_dir = '/tmp/outputs' +_outputs_dir = '/var/run/kfp/parameter' _single_io_file_name = 'data' diff --git a/v2/cacheutils/cache_test.go b/v2/cacheutils/cache_test.go index a9a60cbf6ef7..70719da46deb 100644 --- a/v2/cacheutils/cache_test.go +++ b/v2/cacheutils/cache_test.go @@ -58,8 +58,8 @@ func TestGenerateCacheKey(t *testing.T) { executorInputOutputs: &pipelinespec.ExecutorInput_Outputs{ Parameters: map[string]*pipelinespec.ExecutorInput_OutputParameter{ - "output_parameter_one": {OutputFile: "/tmp/outputs/output_parameter_one/data"}, - "output_parameter_two": {OutputFile: "/tmp/outputs/output_parameter_two/data"}, + "output_parameter_one": {OutputFile: "/var/run/kfp/parameter/output_parameter_one/data"}, + "output_parameter_two": {OutputFile: "/var/run/kfp/parameter/output_parameter_two/data"}, }, Artifacts: map[string]*pipelinespec.ArtifactList{ "model": { diff --git a/v2/compiler/argo_test.go b/v2/compiler/argo_test.go index 7ca4d7665f66..c200c4fc9aff 100644 --- a/v2/compiler/argo_test.go +++ b/v2/compiler/argo_test.go @@ -71,10 +71,10 @@ func Test_argo_compiler(t *testing.T) { parameters: - name: execution-id valueFrom: - path: /tmp/outputs/execution-id + path: /var/run/kfp/parameter/execution-id - name: executor-input valueFrom: - path: /tmp/outputs/executor-input + path: /var/run/kfp/parameter/executor-input - container: args: - sh @@ -247,10 +247,10 @@ func Test_argo_compiler(t *testing.T) { parameters: - name: execution-id valueFrom: - path: /tmp/outputs/execution-id + path: /var/run/kfp/parameter/execution-id - name: context-id valueFrom: - path: /tmp/outputs/context-id + path: /var/run/kfp/parameter/context-id - dag: tasks: - arguments: @@ -284,7 +284,7 @@ func Test_argo_compiler(t *testing.T) { }, { jobPath: "testdata/importer.json", - expectedText: ` + expectedText: ` apiVersion: argoproj.io/v1alpha1 kind: Workflow metadata: @@ -402,10 +402,10 @@ func Test_argo_compiler(t *testing.T) { parameters: - name: execution-id valueFrom: - path: /tmp/outputs/execution-id + path: /var/run/kfp/parameter/execution-id - name: context-id valueFrom: - path: /tmp/outputs/context-id + path: /var/run/kfp/parameter/context-id - dag: tasks: - arguments: diff --git a/v2/compiler/container.go b/v2/compiler/container.go index 3a8d5bed3802..2feba77e4f56 100644 --- a/v2/compiler/container.go +++ b/v2/compiler/container.go @@ -106,8 +106,8 @@ func (c *workflowCompiler) addContainerDriverTemplate() string { }, Outputs: wfapi.Outputs{ Parameters: []wfapi.Parameter{ - {Name: paramExecutionID, ValueFrom: &wfapi.ValueFrom{Path: "/tmp/outputs/execution-id"}}, - {Name: paramExecutorInput, ValueFrom: &wfapi.ValueFrom{Path: "/tmp/outputs/executor-input"}}, + {Name: paramExecutionID, ValueFrom: &wfapi.ValueFrom{Path: "/var/run/kfp/parameter/execution-id"}}, + {Name: paramExecutorInput, ValueFrom: &wfapi.ValueFrom{Path: "/var/run/kfp/parameter/executor-input"}}, }, }, Container: &k8score.Container{ diff --git a/v2/compiler/dag.go b/v2/compiler/dag.go index 1ffe2bfd02ab..a679f322f13d 100644 --- a/v2/compiler/dag.go +++ b/v2/compiler/dag.go @@ -155,8 +155,8 @@ func (c *workflowCompiler) addDAGDriverTemplate() string { }, Outputs: wfapi.Outputs{ Parameters: []wfapi.Parameter{ - {Name: paramExecutionID, ValueFrom: &wfapi.ValueFrom{Path: "/tmp/outputs/execution-id"}}, - {Name: paramContextID, ValueFrom: &wfapi.ValueFrom{Path: "/tmp/outputs/context-id"}}, + {Name: paramExecutionID, ValueFrom: &wfapi.ValueFrom{Path: "/var/run/kfp/parameter/execution-id"}}, + {Name: paramContextID, ValueFrom: &wfapi.ValueFrom{Path: "/var/run/kfp/parameter/context-id"}}, }, }, Container: &k8score.Container{ diff --git a/v2/component/runtime_info_test.go b/v2/component/runtime_info_test.go index 25a268fb24e8..307214b79992 100644 --- a/v2/component/runtime_info_test.go +++ b/v2/component/runtime_info_test.go @@ -95,7 +95,7 @@ func Test_parseRuntimeInfo(t *testing.T) { "outputParameters": { "my_param": { "type": "INT", - "path": "/tmp/outputs/my_param/data" + "path": "/var/run/kfp/parameter/my_param/data" } } }`, @@ -103,7 +103,7 @@ func Test_parseRuntimeInfo(t *testing.T) { OutputParameters: map[string]*outputParameter{ "my_param": { Type: "INT", - Path: "/tmp/outputs/my_param/data", + Path: "/var/run/kfp/parameter/my_param/data", }, }, }, @@ -115,7 +115,7 @@ func Test_parseRuntimeInfo(t *testing.T) { "outputArtifacts": { "my_artifact": { "instanceSchema": "properties:\ntitle: kfp.Dataset\ntype: object\n", - "metadataPath": "/tmp/outputs/my_artifact/data" + "metadataPath": "/var/run/kfp/parameter/my_artifact/data" } } }`, @@ -123,7 +123,7 @@ func Test_parseRuntimeInfo(t *testing.T) { OutputArtifacts: map[string]*outputArtifact{ "my_artifact": { InstanceSchema: "properties:\ntitle: kfp.Dataset\ntype: object\n", - MetadataPath: "/tmp/outputs/my_artifact/data", + MetadataPath: "/var/run/kfp/parameter/my_artifact/data", }, }, }, @@ -212,23 +212,23 @@ func TestExecutorInputGeneration(t *testing.T) { "outputParameters": { "output_parameter_one": { "type": "STRING", - "path": "/tmp/outputs/output_parameter_one/data" + "path": "/var/run/kfp/parameter/output_parameter_one/data" }, "output_parameter_two": { "type": "INT", - "path": "/tmp/outputs/output_parameter_two/data" + "path": "/var/run/kfp/parameter/output_parameter_two/data" } }, "outputArtifacts": { "model": { "schemaTitle": "", "instanceSchema": "title: kfp.Model\ntype: object\nproperties:\n framework:\n type: string\n framework_version:\n type: string\n", - "metadataPath": "/tmp/outputs/model/data" + "metadataPath": "/var/run/kfp/parameter/model/data" }, "metrics": { "schemaTitle": "kfp.Metrics", "instanceSchema": "", - "metadataPath": "/tmp/outputs/metrics/data" + "metadataPath": "/var/run/kfp/parameter/metrics/data" } } }`, dataset_one_path, dataset_two_path), @@ -263,8 +263,8 @@ func TestExecutorInputGeneration(t *testing.T) { }, Outputs: &pipelinespec.ExecutorInput_Outputs{ Parameters: map[string]*pipelinespec.ExecutorInput_OutputParameter{ - "output_parameter_one": {OutputFile: "/tmp/outputs/output_parameter_one/data"}, - "output_parameter_two": {OutputFile: "/tmp/outputs/output_parameter_two/data"}, + "output_parameter_one": {OutputFile: "/var/run/kfp/parameter/output_parameter_one/data"}, + "output_parameter_two": {OutputFile: "/var/run/kfp/parameter/output_parameter_two/data"}, }, Artifacts: map[string]*pipelinespec.ArtifactList{ "model": {