mirror of
https://github.com/TECHNOFAB11/zfs-localpv.git
synced 2026-02-02 07:35:12 +01:00
feat(crd): scripts to help migrating to new CRDs (#73)
The CRDs have changed from being under openebs.io to zfs.openebs.io.
The scripts in this commit and the following steps will help users migrate existing CRDs to new CRDs and clean up older CRDs.
# upgrade to new CRD
1. apply the crd yaml
`$ kubectl apply -f upgrade/crd.yaml`
2. run upgrade.sh
`$ upgrade/upgrade.sh`
3. upgrade the driver to v0.6
`$ kubectl apply -f https://github.com/openebs/zfs-localpv/blob/v0.6.x/deploy/zfs-operator.yaml`
4. if everything looks good run the cleanup.sh, it will clean old CRs and delete the CRD
`$ upgrade/cleanup.sh`
Signed-off-by: Pawan <pawan@mayadata.io>
This commit is contained in:
parent
c4c2278d2f
commit
8a9ac43ab5
3 changed files with 124 additions and 0 deletions
68
upgrade/crd.yaml
Normal file
68
upgrade/crd.yaml
Normal file
|
|
@ -0,0 +1,68 @@
|
|||
##############################################
|
||||
########### ############
|
||||
########### ZFSVolume CRD ############
|
||||
########### ############
|
||||
##############################################
|
||||
apiVersion: apiextensions.k8s.io/v1beta1
|
||||
kind: CustomResourceDefinition
|
||||
metadata:
|
||||
name: zfsvolumes.zfs.openebs.io
|
||||
spec:
|
||||
group: zfs.openebs.io
|
||||
version: v1alpha1
|
||||
scope: Namespaced
|
||||
names:
|
||||
plural: zfsvolumes
|
||||
singular: zfsvolume
|
||||
kind: ZFSVolume
|
||||
shortNames:
|
||||
- zfsvol
|
||||
- zv
|
||||
additionalPrinterColumns:
|
||||
- JSONPath: .spec.poolName
|
||||
name: ZPool
|
||||
description: ZFS Pool where the volume is created
|
||||
type: string
|
||||
- JSONPath: .spec.ownerNodeID
|
||||
name: Node
|
||||
description: Node where the volume is created
|
||||
type: string
|
||||
- JSONPath: .spec.capacity
|
||||
name: Size
|
||||
description: Size of the volume
|
||||
type: string
|
||||
- JSONPath: .spec.volblocksize
|
||||
name: volblocksize
|
||||
description: volblocksize for the created zvol
|
||||
type: string
|
||||
- JSONPath: .spec.recordsize
|
||||
name: recordsize
|
||||
description: recordsize for the created zfs dataset
|
||||
type: string
|
||||
- JSONPath: .spec.fsType
|
||||
name: Filesystem
|
||||
description: filesystem created on the volume
|
||||
type: string
|
||||
---
|
||||
##############################################
|
||||
########### ############
|
||||
########### Snapshot CRD ############
|
||||
########### ############
|
||||
##############################################
|
||||
|
||||
apiVersion: apiextensions.k8s.io/v1beta1
|
||||
kind: CustomResourceDefinition
|
||||
metadata:
|
||||
name: zfssnapshots.zfs.openebs.io
|
||||
spec:
|
||||
group: zfs.openebs.io
|
||||
version: v1alpha1
|
||||
scope: Namespaced
|
||||
names:
|
||||
plural: zfssnapshots
|
||||
singular: zfssnapshot
|
||||
kind: ZFSSnapshot
|
||||
shortNames:
|
||||
- zfssnapshot
|
||||
- zfssnap
|
||||
---
|
||||
Loading…
Add table
Add a link
Reference in a new issue