-
Notifications
You must be signed in to change notification settings - Fork 223
Closed
Labels
kind/bugCategorizes issue or PR as related to a bug.Categorizes issue or PR as related to a bug.
Description
What happened:
MicroShift deploys the kubevirt-hostpath-provisioner and it's respective storageClass, however the SC definition is not set as default. This forces users to explicitly define the SC in PVC specs. This is provides a less-then-ideal storage UX. It also set's up MicroShift workload backwards-incompatibility if kubevirt-hostpath-provisioner is replaced with a different default storage provisioner.
What you expected to happen:
A PVC without .spec.storageClass defined should automatically be provisioned by a default storage class.
How to reproduce it (as minimally and precisely as possible):
- Create a PVC and consumer Pod:
❯ cat <<EOF | oc apply -f -
kind: PersistentVolumeClaim
apiVersion: v1
metadata:
name: pvc-test
spec:
accessModes: [ "ReadWriteOnce" ]
resources:
requests:
storage: 1Gi
---
apiVersion: v1
kind: Pod
metadata:
name: test
spec:
containers:
- name: test
image: nginx
volumeMounts:
- mountPath: /test1
name: my-volume
volumes:
- name: my-volume
persistentVolumeClaim:
claimName: pvc-test
EOF
- Inspect the PV:
Name: pvc-test
Namespace: default
StorageClass:
Status: Pending
Volume:
Labels: <none>
Annotations: <none>
Finalizers: [kubernetes.io/pvc-protection]
Capacity:
Access Modes:
VolumeMode: Filesystem
Used By: test
Events:
Type Reason Age From Message
---- ------ ---- ---- -------
Normal FailedBinding 9s (x4 over 41s) persistentvolume-controller no persistent volumes available for this claim and no storage class is set
Anything else we need to know?:
Environment:
- Microshift version (use
microshift version):
[root@nuc /]# microshift version
MicroShift Version: 4.8.0-0.microshift-2022-03-11-124751-8-g9d6ea58
Base OKD Version: 4.8.0-0.okd-2021-10-10-030117
- OS (e.g:
cat /etc/os-release):
Fedora release 34 (Thirty Four) - Kernel (e.g.
uname -a):
Linux nuc.home.com 5.16.11-100.fc34.x86_64 #1 SMP PREEMPT Wed Feb 23 18:04:40 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux - Others:
Containerized MicroShift Runtime
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
kind/bugCategorizes issue or PR as related to a bug.Categorizes issue or PR as related to a bug.