diff --git a/backend/src/v2/compiler/argocompiler/container.go b/backend/src/v2/compiler/argocompiler/container.go index d674308fa00..9d000a90211 100644 --- a/backend/src/v2/compiler/argocompiler/container.go +++ b/backend/src/v2/compiler/argocompiler/container.go @@ -42,6 +42,8 @@ const ( dotLocalScratchName = "dot-local-scratch" dotCacheScratchLocation = "/.cache" dotCacheScratchName = "dot-cache-scratch" + dotConfigScratchLocation = "/.config" + dotConfigScratchName = "dot-config-scratch" ) func (c *workflowCompiler) Container(name string, component *pipelinespec.ComponentSpec, container *pipelinespec.PipelineDeploymentConfig_PipelineContainerSpec) error { @@ -289,6 +291,12 @@ func (c *workflowCompiler) addContainerExecutorTemplate() string { EmptyDir: &k8score.EmptyDirVolumeSource{}, }, }, + { + Name: dotConfigScratchName, + VolumeSource: k8score.VolumeSource{ + EmptyDir: &k8score.EmptyDirVolumeSource{}, + }, + }, }, InitContainers: []wfapi.UserContainer{{ Container: k8score.Container{ @@ -338,6 +346,10 @@ func (c *workflowCompiler) addContainerExecutorTemplate() string { Name: dotCacheScratchName, MountPath: dotCacheScratchLocation, }, + { + Name: dotConfigScratchName, + MountPath: dotConfigScratchLocation, + }, }, EnvFrom: []k8score.EnvFromSource{metadataEnvFrom}, Env: commonEnvs, diff --git a/backend/src/v2/compiler/argocompiler/testdata/create_mount_delete_dynamic_pvc.yaml b/backend/src/v2/compiler/argocompiler/testdata/create_mount_delete_dynamic_pvc.yaml index dad0b7dd1ac..e3b427d2455 100644 --- a/backend/src/v2/compiler/argocompiler/testdata/create_mount_delete_dynamic_pvc.yaml +++ b/backend/src/v2/compiler/argocompiler/testdata/create_mount_delete_dynamic_pvc.yaml @@ -152,6 +152,8 @@ spec: name: dot-local-scratch - mountPath: /.cache name: dot-cache-scratch + - mountPath: /.config + name: dot-config-scratch initContainers: - command: - launcher-v2 @@ -188,6 +190,8 @@ spec: name: dot-local-scratch - emptyDir: { } name: dot-cache-scratch + - emptyDir: { } + name: dot-config-scratch - dag: tasks: - arguments: diff --git a/backend/src/v2/compiler/argocompiler/testdata/hello_world.yaml b/backend/src/v2/compiler/argocompiler/testdata/hello_world.yaml index ff77e358897..5685ece5de5 100644 --- a/backend/src/v2/compiler/argocompiler/testdata/hello_world.yaml +++ b/backend/src/v2/compiler/argocompiler/testdata/hello_world.yaml @@ -135,6 +135,8 @@ spec: name: dot-local-scratch - mountPath: /.cache name: dot-cache-scratch + - mountPath: /.config + name: dot-config-scratch initContainers: - command: - launcher-v2 @@ -171,6 +173,8 @@ spec: name: dot-local-scratch - emptyDir: {} name: dot-cache-scratch + - emptyDir: {} + name: dot-config-scratch - dag: tasks: - arguments: