mirror of
https://github.com/openshift/openshift-docs.git
synced 2026-02-06 06:46:26 +01:00
43 lines
1.2 KiB
Plaintext
43 lines
1.2 KiB
Plaintext
// Module included in the following assembly:
|
|
//
|
|
// * virt/virtual_machines/advanced_vm_management/virt-automatic-bootsource-updates.adoc
|
|
//
|
|
|
|
:_content-type: PROCEDURE
|
|
[id="virt-configuring-storage-class-bootsource-update_{context}"]
|
|
= Configuring a storage class for user-defined boot source updates
|
|
|
|
You can configure a storage class that allows automatic importing and updating for user-defined boot sources.
|
|
|
|
.Procedure
|
|
|
|
. Define a new `storageClassName` by editing the `HyperConverged` custom resource (CR).
|
|
+
|
|
[source,yaml]
|
|
----
|
|
apiVersion: hco.kubevirt.io/v1beta1
|
|
kind: HyperConverged
|
|
metadata:
|
|
name: kubevirt-hyperconverged
|
|
spec:
|
|
dataImportCronTemplates:
|
|
- metadata:
|
|
name: rhel8-image-cron
|
|
spec:
|
|
template:
|
|
spec:
|
|
storageClassName: <appropriate_class_name>
|
|
...
|
|
----
|
|
. Set the new default storage class by running the following commands:
|
|
+
|
|
[source,terminal]
|
|
----
|
|
$ oc patch storageclass <current_default_storage_class> -p '{"metadata": {"annotations":{"storageclass.kubernetes.io/is-default-class":"false"}}}'
|
|
----
|
|
+
|
|
[source,terminal]
|
|
----
|
|
$ oc patch storageclass <appropriate_storage_class> -p '{"metadata": {"annotations":{"storageclass.kubernetes.io/is-default-class":"true"}}}'
|
|
----
|