Skip to content

Feature Request: Support volumeClaimTemplates in SandboxTemplate / SandboxClaim #225

@panchalravi

Description

@panchalravi

Currently, it is possible to create a Sandbox with a PersistentVolume using volumeClaimTemplates directly on the Sandbox spec.

For example:

apiVersion: agents.x-k8s.io/v1alpha1
kind: Sandbox
metadata:
  name: my-sandbox
spec:
  podTemplate:
    spec:
      containers:
        - name: app
          image: ghcr.io/example/agent:latest
          volumeMounts:
            - name: data
              mountPath: /data
  volumeClaimTemplates:
    - metadata:
        name: data
      spec:
        accessModes: ["ReadWriteOnce"]
        resources:
          requests:
            storage: 10Gi
        storageClassName: standard

This ensures that the sandbox gets its own persistent volume backed by a PVC created from the template.

However, creating sandboxes using SandboxClaim and SandboxTemplate does not currently support volumeClaimTemplates on the SandboxTemplate.

Allow SandboxTemplate.spec.podTemplate.spec.volumes to accept a volumeClaimTemplates, mirroring the schema and behavior of Sandbox.spec.volumeClaimTemplates so that each sandbox created via a SandboxClaim from that template will get its own PVC and associated persistent volume.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions