From ec88b6aaa48067fd6a3bd9c0c45d8871a230ca64 Mon Sep 17 00:00:00 2001 From: jgrusewski Date: Tue, 31 Mar 2026 10:20:06 +0200 Subject: [PATCH] fix: add volumes to all train-* templates for compile-and-train compat templateRef doesn't inherit workflow-level volumes from the referenced template. All 3 train wrappers (DQN, PPO, supervised) now define git-ssh-key, training-data, cargo-target-cuda volumes and workspace volumeClaimTemplate locally. Co-Authored-By: Claude Opus 4.6 (1M context) --- infra/k8s/argo/train-dqn-template.yaml | 24 +++++++++++++++++++ infra/k8s/argo/train-ppo-template.yaml | 24 +++++++++++++++++++ infra/k8s/argo/train-supervised-template.yaml | 24 +++++++++++++++++++ 3 files changed, 72 insertions(+) diff --git a/infra/k8s/argo/train-dqn-template.yaml b/infra/k8s/argo/train-dqn-template.yaml index 34a2a39ce..840621519 100644 --- a/infra/k8s/argo/train-dqn-template.yaml +++ b/infra/k8s/argo/train-dqn-template.yaml @@ -65,6 +65,30 @@ spec: - name: cuda-compute-cap value: "90" + # Volumes required by compile-and-train steps + volumes: + - name: git-ssh-key + secret: + secretName: argo-git-ssh-key + defaultMode: 256 + - name: training-data + persistentVolumeClaim: + claimName: training-data-pvc + readOnly: true + - name: cargo-target-cuda + persistentVolumeClaim: + claimName: cargo-target-cuda + + volumeClaimTemplates: + - metadata: + name: workspace + spec: + accessModes: ["ReadWriteOnce"] + storageClassName: scw-bssd + resources: + requests: + storage: 5Gi + templates: - name: pipeline steps: diff --git a/infra/k8s/argo/train-ppo-template.yaml b/infra/k8s/argo/train-ppo-template.yaml index 607fea7c1..f8a5a04bf 100644 --- a/infra/k8s/argo/train-ppo-template.yaml +++ b/infra/k8s/argo/train-ppo-template.yaml @@ -69,6 +69,30 @@ spec: - name: cuda-compute-cap value: "90" + # Volumes required by compile-and-train steps + volumes: + - name: git-ssh-key + secret: + secretName: argo-git-ssh-key + defaultMode: 256 + - name: training-data + persistentVolumeClaim: + claimName: training-data-pvc + readOnly: true + - name: cargo-target-cuda + persistentVolumeClaim: + claimName: cargo-target-cuda + + volumeClaimTemplates: + - metadata: + name: workspace + spec: + accessModes: ["ReadWriteOnce"] + storageClassName: scw-bssd + resources: + requests: + storage: 5Gi + templates: - name: pipeline steps: diff --git a/infra/k8s/argo/train-supervised-template.yaml b/infra/k8s/argo/train-supervised-template.yaml index 62959d2ea..001020176 100644 --- a/infra/k8s/argo/train-supervised-template.yaml +++ b/infra/k8s/argo/train-supervised-template.yaml @@ -73,6 +73,30 @@ spec: - name: cuda-compute-cap value: "90" + # Volumes required by compile-and-train steps + volumes: + - name: git-ssh-key + secret: + secretName: argo-git-ssh-key + defaultMode: 256 + - name: training-data + persistentVolumeClaim: + claimName: training-data-pvc + readOnly: true + - name: cargo-target-cuda + persistentVolumeClaim: + claimName: cargo-target-cuda + + volumeClaimTemplates: + - metadata: + name: workspace + spec: + accessModes: ["ReadWriteOnce"] + storageClassName: scw-bssd + resources: + requests: + storage: 5Gi + templates: - name: pipeline steps: