-
I'm trying out this custom storage example from Kubernetes official docs but it doesn't seem to work. Is there something else required for getting custom storage classes to work or is it not supported? Manifest:
Storage class stuck at pending:
Should this require some other step to get it working or am I missing something? I use kwok mainly for testing some Python services. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
This example is missing the PV, so it doesn't work here is a PV apiVersion: v1
kind: PersistentVolume
metadata:
name: pv-volume
labels:
type: local
spec:
storageClassName: "my-storage-class"
capacity:
storage: 10Gi
accessModes:
- ReadWriteOnce
hostPath:
path: "/mnt/data" In addition, Node also needs to be created apiVersion: v1
kind: Node
metadata:
annotations:
node.alpha.kubernetes.io/ttl: "0"
kwok.x-k8s.io/node: fake
labels:
beta.kubernetes.io/arch: amd64
beta.kubernetes.io/os: linux
kubernetes.io/arch: amd64
kubernetes.io/hostname: kwok-node-1
kubernetes.io/os: linux
kubernetes.io/role: agent
node-role.kubernetes.io/agent: ""
type: kwok
name: kwok-node-1
status:
allocatable:
cpu: 32
memory: 256Gi
pods: 110
capacity:
cpu: 32
memory: 256Gi
pods: 110
nodeInfo:
architecture: amd64
bootID: ""
containerRuntimeVersion: ""
kernelVersion: ""
kubeProxyVersion: fake
kubeletVersion: fake
machineID: ""
operatingSystem: linux
osImage: ""
systemUUID: ""
phase: Running |
Beta Was this translation helpful? Give feedback.
-
Thanks @wzshiming. Very much appreicate it! |
Beta Was this translation helpful? Give feedback.
This example is missing the PV, so it doesn't work
here is a PV
In addition, Node also needs to be created