Storage class portability limits between Rancher Desktop and production clusters
0 reputation · 18 May 2024, 21:17 UTC
0 reputation · 18 May 2024, 21:17 UTC
Rancher supports local development via Rancher Desktop and production workloads via Rancher Server managing downstream clusters. A common goal is to author manifests locally and promote them unchanged to production.
Local development environments often default to storage classes such as local-path that are provided for single-node convenience. Production-managed clusters may use different provisioners and may not expose the same default storage class. Rancher also applies project and namespace isolation with admission controls that can differ between environments.
The behavior of PVC binding and security context enforcement is therefore environment-dependent, and the portability of manifests is not guaranteed by Rancher alone.
Is there a documented Rancher capability to validate that a PVC's storage class exists in a target downstream cluster before applying manifests? What is the supported behavior when a workload references a default storage class that is absent in production? Does Rancher provide project-level warnings for cluster-specific capabilities such as local-path or privileged security contexts?
No. Rancher does not provide a built-in pre-apply validation that checks whether a PVC's storageClassName exists in a target downstream cluster before manifests are applied. Validation happens only after the object is submitted to the Kubernetes API.
If a workload references a storage class that is absent in production, the PVC stays Pending and Kubernetes reports the class is not found. Rancher UI reflects the Pending status but does not auto-substitute or create the class.
Rancher does not provide project-level warnings for cluster-specific capabilities such as local-path or privileged security contexts. Enforcement of those restrictions requires external admission control.
Rancher Desktop typically provisions a single-node convenience class such as local-path. Production downstream clusters managed by Rancher Server use different provisioners and may have no equivalent class. Because Rancher does not normalize storage class names across environments, manifests authored locally bind locally but remain Pending in production.
kubectl get storageclass -n kube-system from the Rancher context.storageClassName references and replace them with a portable name or omit the field to use the project default.One missing diagnostic detail that changes the recommendation: which Rancher Server version and whether you promote manifests via Rancher Fleet/GitOps. Fleet can add pre-apply dry-run checks that Rancher UI alone does not provide.
Use comments to ask for clarification. Post a solution as an answer.
No question comments on this page.