This repository has been archived by the owner on May 8, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 96
/
cstor-operator.yaml
6073 lines (6046 loc) · 285 KB
/
cstor-operator.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
# This manifest is autogenerated via 'make manifests' command.
# Do the modification to the yamls in deploy/yamls/ directory
# and then run 'make manifests' command
#
# NDM Operator YAML will be downladed from github.com/openebs/node-disk-manager repo
# Create the OpenEBS namespace
apiVersion: v1
kind: Namespace
metadata:
name: openebs
---
# Create Maya Service Account
apiVersion: v1
kind: ServiceAccount
metadata:
name: openebs-cstor-operator
namespace: openebs
---
# Define Role that allows operations on K8s pods/deployments
kind: ClusterRole
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: openebs-cstor-operator
rules:
- apiGroups: ["*"]
resources: ["nodes", "nodes/proxy"]
verbs: ["*"]
- apiGroups: ["*"]
resources: ["namespaces", "services", "pods", "deployments", "deployments/finalizers", "replicationcontrollers", "replicasets", "events", "endpoints", "configmaps", "secrets", "jobs", "cronjobs"]
verbs: ["*"]
- apiGroups: ["*"]
resources: ["statefulsets", "daemonsets"]
verbs: ["*"]
- apiGroups: ["*"]
resources: ["resourcequotas", "limitranges"]
verbs: ["list", "watch"]
- apiGroups: ["*"]
resources: ["certificatesigningrequests"]
verbs: ["list", "watch"]
- apiGroups: ["*"]
resources: ["storageclasses", "persistentvolumeclaims", "persistentvolumes"]
verbs: ["*"]
- apiGroups: ["apiextensions.k8s.io"]
resources: ["customresourcedefinitions"]
verbs: [ "get", "list", "create", "update", "delete", "patch"]
- apiGroups: ["openebs.io"]
resources: ["*"]
verbs: ["*" ]
- apiGroups: ["cstor.openebs.io"]
resources: ["*"]
verbs: ["*" ]
- apiGroups: ["coordination.k8s.io"]
resources: ["leases"]
verbs: ["get", "watch", "list", "delete", "update", "create"]
- apiGroups: ["admissionregistration.k8s.io"]
resources: ["validatingwebhookconfigurations", "mutatingwebhookconfigurations"]
verbs: ["get", "create", "list", "delete", "update", "patch"]
- nonResourceURLs: ["/metrics"]
verbs: ["get"]
- apiGroups: ["*"]
resources: ["upgradetasks", "migrationtasks"]
verbs: ["*"]
- apiGroups: ["*"]
resources: ["poddisruptionbudgets"]
verbs: ["get", "list", "create", "delete", "watch"]
---
# Bind the Service Account with the Role Privileges.
kind: ClusterRoleBinding
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: openebs-cstor-operator
subjects:
- kind: ServiceAccount
name: openebs-cstor-operator
namespace: openebs
roleRef:
kind: ClusterRole
name: openebs-cstor-operator
apiGroup: rbac.authorization.k8s.io
---
# Define Role that allows operations required for migration of snapshots
kind: ClusterRole
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: openebs-cstor-migration
rules:
- apiGroups: ["snapshot.storage.k8s.io"]
resources: ["volumesnapshotclasses"]
verbs: ["get", "list"]
- apiGroups: ["snapshot.storage.k8s.io"]
resources: ["volumesnapshotcontents"]
verbs: ["create", "get", "list"]
- apiGroups: ["snapshot.storage.k8s.io"]
resources: ["volumesnapshots"]
verbs: ["create", "get", "list"]
---
kind: ClusterRoleBinding
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: openebs-cstor-migration
subjects:
- kind: ServiceAccount
name: openebs-cstor-operator
namespace: openebs
roleRef:
kind: ClusterRole
name: openebs-cstor-migration
apiGroup: rbac.authorization.k8s.io
---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.10.0
creationTimestamp: null
name: cstorbackups.cstor.openebs.io
spec:
group: cstor.openebs.io
names:
kind: CStorBackup
listKind: CStorBackupList
plural: cstorbackups
shortNames:
- cbackup
singular: cstorbackup
scope: Namespaced
versions:
- additionalPrinterColumns:
- description: Name of the volume for which this backup is destined
jsonPath: .spec.volumeName
name: Volume
type: string
- description: Name of the backup or scheduled backup
jsonPath: .spec.backupName
name: Backup/Schedule
type: string
- description: Identifies the phase of the backup
jsonPath: .status
name: Status
type: string
name: v1
schema:
openAPIV3Schema:
description: CStorBackup describes a cstor backup resource created as a custom
resource
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation
of an object. Servers should convert recognized schemas to the latest
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
kind:
description: 'Kind is a string value representing the REST resource this
object represents. Servers may infer this from the endpoint the client
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
type: string
metadata:
type: object
spec:
description: CStorBackupSpec is the spec for a CStorBackup resource
properties:
backupDest:
description: BackupDest is the remote address for backup transfer
type: string
backupName:
description: BackupName is the name of the backup or scheduled backup
type: string
localSnap:
description: LocalSnap is the flag to enable local snapshot only
type: boolean
prevSnapName:
description: PrevSnapName is the last completed-backup's snapshot
name
type: string
snapName:
description: SnapName is the name of the current backup snapshot
type: string
volumeName:
description: VolumeName is the name of the volume for which this backup
is destined
type: string
required:
- backupName
- snapName
- volumeName
type: object
status:
description: CStorBackupStatus is a string type that represents the status
of the backup
type: string
required:
- spec
type: object
served: true
storage: true
subresources: {}
---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.10.0
creationTimestamp: null
name: cstorcompletedbackups.cstor.openebs.io
spec:
group: cstor.openebs.io
names:
kind: CStorCompletedBackup
listKind: CStorCompletedBackupList
plural: cstorcompletedbackups
shortNames:
- ccompletedbackup
singular: cstorcompletedbackup
scope: Namespaced
versions:
- additionalPrinterColumns:
- description: Volume name on which backup is performed
jsonPath: .spec.volumeName
name: Volume
type: string
- description: Name of the backup or scheduled backup
jsonPath: .spec.backupName
name: Backup/Schedule
type: string
- description: Last successfully backup snapshot
jsonPath: .spec.lastSnapName
name: LastSnap
type: string
name: v1
schema:
openAPIV3Schema:
description: CStorCompletedBackup describes a cstor completed-backup resource
created as custom resource
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation
of an object. Servers should convert recognized schemas to the latest
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
kind:
description: 'Kind is a string value representing the REST resource this
object represents. Servers may infer this from the endpoint the client
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
type: string
metadata:
type: object
spec:
description: CStorCompletedBackupSpec is the spec for a CStorBackup resource
properties:
backupName:
description: BackupName is the name of backup or scheduled backup
type: string
lastSnapName:
description: LastSnapName is the name of last completed-backup's snapshot
name
type: string
secondLastSnapName:
description: SecondLastSnapName is the name of second last 'successfully'
completed-backup's snapshot
type: string
volumeName:
description: VolumeName is the name of volume for which this backup
is destined
type: string
type: object
required:
- spec
type: object
served: true
storage: true
subresources: {}
---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.10.0
creationTimestamp: null
name: cstorpoolclusters.cstor.openebs.io
spec:
group: cstor.openebs.io
names:
kind: CStorPoolCluster
listKind: CStorPoolClusterList
plural: cstorpoolclusters
shortNames:
- cspc
singular: cstorpoolcluster
scope: Namespaced
versions:
- additionalPrinterColumns:
- description: The number of healthy cStorPoolInstances
jsonPath: .status.healthyInstances
name: HealthyInstances
type: integer
- description: The number of provisioned cStorPoolInstances
jsonPath: .status.provisionedInstances
name: ProvisionedInstances
type: integer
- description: The number of desired cStorPoolInstances
jsonPath: .status.desiredInstances
name: DesiredInstances
type: integer
- description: Age of CStorPoolCluster
jsonPath: .metadata.creationTimestamp
name: Age
type: date
name: v1
schema:
openAPIV3Schema:
description: CStorPoolCluster describes a CStorPoolCluster custom resource.
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation
of an object. Servers should convert recognized schemas to the latest
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
kind:
description: 'Kind is a string value representing the REST resource this
object represents. Servers may infer this from the endpoint the client
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
type: string
metadata:
type: object
spec:
description: CStorPoolClusterSpec is the spec for a CStorPoolClusterSpec
resource
properties:
auxResources:
description: AuxResources are the compute resources required by the
cstor-pool pod side car containers.
nullable: true
properties:
limits:
additionalProperties:
anyOf:
- type: integer
- type: string
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
x-kubernetes-int-or-string: true
description: 'Limits describes the maximum amount of compute resources
allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/'
type: object
requests:
additionalProperties:
anyOf:
- type: integer
- type: string
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
x-kubernetes-int-or-string: true
description: 'Requests describes the minimum amount of compute
resources required. If Requests is omitted for a container,
it defaults to Limits if that is explicitly specified, otherwise
to an implementation-defined value. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/'
type: object
type: object
pools:
description: Pools is the spec for pools for various nodes where it
should be created.
items:
description: PoolSpec is the spec for pool on node where it should
be created.
properties:
dataRaidGroups:
description: DataRaidGroups is the raid group configuration
for the given pool.
items:
description: RaidGroup contains the details of a raid group
for the pool
properties:
blockDevices:
items:
description: CStorPoolInstanceBlockDevice contains the
details of block devices that constitutes a raid group.
properties:
blockDeviceName:
description: BlockDeviceName is the name of the
block device.
type: string
capacity:
description: Capacity is the capacity of the block
device. It is system generated
format: int64
type: integer
devLink:
description: DevLink is the dev link for block devices
type: string
required:
- blockDeviceName
type: object
type: array
required:
- blockDevices
type: object
type: array
nodeSelector:
additionalProperties:
type: string
description: NodeSelector is the labels that will be used to
select a node for pool provisioning. Required field
type: object
poolConfig:
description: PoolConfig is the default pool config that applies
to the pool on node.
properties:
auxResources:
description: AuxResources are the compute resources required
by the cstor-pool pod side car containers.
nullable: true
properties:
limits:
additionalProperties:
anyOf:
- type: integer
- type: string
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
x-kubernetes-int-or-string: true
description: 'Limits describes the maximum amount of
compute resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/'
type: object
requests:
additionalProperties:
anyOf:
- type: integer
- type: string
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
x-kubernetes-int-or-string: true
description: 'Requests describes the minimum amount
of compute resources required. If Requests is omitted
for a container, it defaults to Limits if that is
explicitly specified, otherwise to an implementation-defined
value. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/'
type: object
type: object
compression:
description: 'Compression to enable compression Optional
-- defaults to off Possible values : lz, off'
type: string
dataRaidGroupType:
description: DataRaidGroupType is the raid type.
type: string
priorityClassName:
description: PriorityClassName if specified applies to this
pool pod If left empty, DefaultPriorityClassName is applied.
(See CStorPoolClusterSpec.DefaultPriorityClassName) If
both are empty, not priority class is applied.
nullable: true
type: string
resources:
description: Resources are the compute resources required
by the cstor-pool container.
nullable: true
properties:
limits:
additionalProperties:
anyOf:
- type: integer
- type: string
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
x-kubernetes-int-or-string: true
description: 'Limits describes the maximum amount of
compute resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/'
type: object
requests:
additionalProperties:
anyOf:
- type: integer
- type: string
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
x-kubernetes-int-or-string: true
description: 'Requests describes the minimum amount
of compute resources required. If Requests is omitted
for a container, it defaults to Limits if that is
explicitly specified, otherwise to an implementation-defined
value. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/'
type: object
type: object
roThresholdLimit:
description: 'ROThresholdLimit is threshold(percentage base)
limit for pool read only mode. If ROThresholdLimit(%)
amount of pool storage is reached then pool will set to
readonly. NOTE: 1. If ROThresholdLimit is set to 100 then
entire pool storage will be used by default it will be
set to 85%. 2. ROThresholdLimit value will be 0 <= ROThresholdLimit
<= 100.'
nullable: true
type: integer
thickProvision:
description: ThickProvision to enable thick provisioning
Optional -- defaults to false
type: boolean
tolerations:
description: Tolerations, if specified, the pool pod's tolerations.
items:
description: The pod this Toleration is attached to tolerates
any taint that matches the triple <key,value,effect>
using the matching operator <operator>.
properties:
effect:
description: Effect indicates the taint effect to
match. Empty means match all taint effects. When
specified, allowed values are NoSchedule, PreferNoSchedule
and NoExecute.
type: string
key:
description: Key is the taint key that the toleration
applies to. Empty means match all taint keys. If
the key is empty, operator must be Exists; this
combination means to match all values and all keys.
type: string
operator:
description: Operator represents a key's relationship
to the value. Valid operators are Exists and Equal.
Defaults to Equal. Exists is equivalent to wildcard
for value, so that a pod can tolerate all taints
of a particular category.
type: string
tolerationSeconds:
description: TolerationSeconds represents the period
of time the toleration (which must be of effect
NoExecute, otherwise this field is ignored) tolerates
the taint. By default, it is not set, which means
tolerate the taint forever (do not evict). Zero
and negative values will be treated as 0 (evict
immediately) by the system.
format: int64
type: integer
value:
description: Value is the taint value the toleration
matches to. If the operator is Exists, the value
should be empty, otherwise just a regular string.
type: string
type: object
nullable: true
type: array
writeCacheGroupType:
description: WriteCacheGroupType is the write cache raid
type.
type: string
required:
- dataRaidGroupType
type: object
writeCacheRaidGroups:
description: WriteCacheRaidGroups is the write cache raid group.
items:
description: RaidGroup contains the details of a raid group
for the pool
properties:
blockDevices:
items:
description: CStorPoolInstanceBlockDevice contains the
details of block devices that constitutes a raid group.
properties:
blockDeviceName:
description: BlockDeviceName is the name of the
block device.
type: string
capacity:
description: Capacity is the capacity of the block
device. It is system generated
format: int64
type: integer
devLink:
description: DevLink is the dev link for block devices
type: string
required:
- blockDeviceName
type: object
type: array
required:
- blockDevices
type: object
nullable: true
type: array
required:
- dataRaidGroups
- nodeSelector
type: object
type: array
priorityClassName:
description: DefaultPriorityClassName if specified applies to all
the pool pods in the pool spec if the priorityClass at the pool
level is not specified.
type: string
resources:
description: DefaultResources are the compute resources required by
the cstor-pool container. If the resources at PoolConfig is not
specified, this is written to CSPI PoolConfig.
nullable: true
properties:
limits:
additionalProperties:
anyOf:
- type: integer
- type: string
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
x-kubernetes-int-or-string: true
description: 'Limits describes the maximum amount of compute resources
allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/'
type: object
requests:
additionalProperties:
anyOf:
- type: integer
- type: string
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
x-kubernetes-int-or-string: true
description: 'Requests describes the minimum amount of compute
resources required. If Requests is omitted for a container,
it defaults to Limits if that is explicitly specified, otherwise
to an implementation-defined value. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/'
type: object
type: object
tolerations:
description: Tolerations, if specified, are the pool pod's tolerations
If tolerations at PoolConfig is empty, this is written to CSPI PoolConfig.
items:
description: The pod this Toleration is attached to tolerates any
taint that matches the triple <key,value,effect> using the matching
operator <operator>.
properties:
effect:
description: Effect indicates the taint effect to match. Empty
means match all taint effects. When specified, allowed values
are NoSchedule, PreferNoSchedule and NoExecute.
type: string
key:
description: Key is the taint key that the toleration applies
to. Empty means match all taint keys. If the key is empty,
operator must be Exists; this combination means to match all
values and all keys.
type: string
operator:
description: Operator represents a key's relationship to the
value. Valid operators are Exists and Equal. Defaults to Equal.
Exists is equivalent to wildcard for value, so that a pod
can tolerate all taints of a particular category.
type: string
tolerationSeconds:
description: TolerationSeconds represents the period of time
the toleration (which must be of effect NoExecute, otherwise
this field is ignored) tolerates the taint. By default, it
is not set, which means tolerate the taint forever (do not
evict). Zero and negative values will be treated as 0 (evict
immediately) by the system.
format: int64
type: integer
value:
description: Value is the taint value the toleration matches
to. If the operator is Exists, the value should be empty,
otherwise just a regular string.
type: string
type: object
nullable: true
type: array
type: object
status:
description: CStorPoolClusterStatus represents the latest available observations
of a CSPC's current state.
properties:
conditions:
description: Current state of CSPC.
items:
description: CStorPoolClusterCondition describes the state of a
CSPC at a certain point.
properties:
lastTransitionTime:
description: Last time the condition transitioned from one status
to another.
format: date-time
type: string
lastUpdateTime:
description: The last time this condition was updated.
format: date-time
type: string
message:
description: A human readable message indicating details about
the transition.
type: string
reason:
description: The reason for the condition's last transition.
type: string
status:
description: Status of the condition, one of True, False, Unknown.
type: string
type:
description: Type of CSPC condition.
type: string
required:
- status
- type
type: object
nullable: true
type: array
desiredInstances:
description: DesiredInstances is the number of CSPI(s) that should
be provisioned.
format: int32
nullable: true
type: integer
healthyInstances:
description: HealthyInstances is the number of CSPI(s) that are healthy.
format: int32
nullable: true
type: integer
provisionedInstances:
description: ProvisionedInstances is the the number of CSPI present
at the current state.
format: int32
nullable: true
type: integer
type: object
versionDetails:
description: VersionDetails provides the details for upgrade
properties:
autoUpgrade:
description: If AutoUpgrade is set to true then the resource is upgraded
automatically without any manual steps
type: boolean
desired:
description: Desired is the version that we want to upgrade or the
control plane version
type: string
status:
description: Status gives the status of reconciliation triggered when
the desired and current version are not same
properties:
current:
description: Current is the version of resource
type: string
dependentsUpgraded:
description: DependentsUpgraded gives the details whether all
children of a resource are upgraded to desired version or not
type: boolean
lastUpdateTime:
description: LastUpdateTime is the time the status was last updated
format: date-time
nullable: true
type: string
message:
description: Message is a human readable message if some error
occurs
type: string
reason:
description: Reason is the actual reason for the error state
type: string
state:
description: State is the state of reconciliation
type: string
type: object
type: object
required:
- spec
type: object
served: true
storage: true
subresources: {}
---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.10.0
creationTimestamp: null
name: cstorpoolinstances.cstor.openebs.io
spec:
group: cstor.openebs.io
names:
kind: CStorPoolInstance
listKind: CStorPoolInstanceList
plural: cstorpoolinstances
shortNames:
- cspi
singular: cstorpoolinstance
scope: Namespaced
versions:
- additionalPrinterColumns:
- description: Host name where cstorpool instances scheduled
jsonPath: .spec.hostName
name: HostName
type: string
- description: The amount of storage space within the pool that has been physically
allocated
jsonPath: .status.capacity.used
name: Allocated
priority: 1
type: string
- description: The amount of usable free space available in the pool
jsonPath: .status.capacity.free
name: Free
type: string
- description: Total amount of usable space in pool
jsonPath: .status.capacity.total
name: Capacity
type: string
- description: Identifies the pool read only mode
jsonPath: .status.readOnly
name: ReadOnly
type: boolean
- description: Represents no.of replicas present in the pool
jsonPath: .status.provisionedReplicas
name: ProvisionedReplicas
type: integer
- description: Represents no.of healthy replicas present in the pool
jsonPath: .status.healthyReplicas
name: HealthyReplicas
type: integer
- description: Represents the type of the storage pool
jsonPath: .spec.poolConfig.dataRaidGroupType
name: Type
priority: 1
type: string
- description: Identifies the current health of the pool
jsonPath: .status.phase
name: Status
type: string
- description: Age of CStorPoolInstance
jsonPath: .metadata.creationTimestamp
name: Age
type: date
name: v1
schema:
openAPIV3Schema:
description: CStorPoolInstance describes a cstor pool instance resource.
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation
of an object. Servers should convert recognized schemas to the latest
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
kind:
description: 'Kind is a string value representing the REST resource this
object represents. Servers may infer this from the endpoint the client
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
type: string
metadata:
type: object
spec:
description: Spec is the specification of the cstorpoolinstance resource.
properties:
dataRaidGroups:
description: DataRaidGroups is the raid group configuration for the
given pool.
items:
description: RaidGroup contains the details of a raid group for
the pool
properties:
blockDevices:
items:
description: CStorPoolInstanceBlockDevice contains the details
of block devices that constitutes a raid group.
properties:
blockDeviceName:
description: BlockDeviceName is the name of the block
device.
type: string
capacity:
description: Capacity is the capacity of the block device.
It is system generated
format: int64
type: integer
devLink:
description: DevLink is the dev link for block devices
type: string
required:
- blockDeviceName
type: object
type: array
required:
- blockDevices
type: object
type: array
hostName:
description: HostName is the name of kubernetes node where the pool
should be created.
type: string
nodeSelector:
additionalProperties:
type: string
description: NodeSelector is the labels that will be used to select
a node for pool provisioning. Required field
type: object
poolConfig:
description: PoolConfig is the default pool config that applies to
the pool on node.
properties:
auxResources:
description: AuxResources are the compute resources required by
the cstor-pool pod side car containers.
nullable: true
properties:
limits:
additionalProperties:
anyOf:
- type: integer
- type: string
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
x-kubernetes-int-or-string: true
description: 'Limits describes the maximum amount of compute
resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/'
type: object
requests:
additionalProperties:
anyOf:
- type: integer
- type: string
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
x-kubernetes-int-or-string: true
description: 'Requests describes the minimum amount of compute
resources required. If Requests is omitted for a container,
it defaults to Limits if that is explicitly specified, otherwise
to an implementation-defined value. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/'
type: object
type: object
compression:
description: 'Compression to enable compression Optional -- defaults
to off Possible values : lz, off'
type: string
dataRaidGroupType:
description: DataRaidGroupType is the raid type.
type: string
priorityClassName:
description: PriorityClassName if specified applies to this pool
pod If left empty, DefaultPriorityClassName is applied. (See
CStorPoolClusterSpec.DefaultPriorityClassName) If both are empty,
not priority class is applied.
nullable: true
type: string
resources:
description: Resources are the compute resources required by the
cstor-pool container.
nullable: true
properties:
limits:
additionalProperties:
anyOf:
- type: integer
- type: string
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
x-kubernetes-int-or-string: true
description: 'Limits describes the maximum amount of compute
resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/'
type: object
requests:
additionalProperties:
anyOf:
- type: integer
- type: string
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
x-kubernetes-int-or-string: true
description: 'Requests describes the minimum amount of compute
resources required. If Requests is omitted for a container,
it defaults to Limits if that is explicitly specified, otherwise
to an implementation-defined value. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/'
type: object
type: object
roThresholdLimit:
description: 'ROThresholdLimit is threshold(percentage base) limit
for pool read only mode. If ROThresholdLimit(%) amount of pool
storage is reached then pool will set to readonly. NOTE: 1.
If ROThresholdLimit is set to 100 then entire pool storage will
be used by default it will be set to 85%. 2. ROThresholdLimit
value will be 0 <= ROThresholdLimit <= 100.'
nullable: true
type: integer
thickProvision:
description: ThickProvision to enable thick provisioning Optional
-- defaults to false
type: boolean
tolerations:
description: Tolerations, if specified, the pool pod's tolerations.
items:
description: The pod this Toleration is attached to tolerates
any taint that matches the triple <key,value,effect> using
the matching operator <operator>.
properties:
effect:
description: Effect indicates the taint effect to match.
Empty means match all taint effects. When specified, allowed
values are NoSchedule, PreferNoSchedule and NoExecute.
type: string
key:
description: Key is the taint key that the toleration applies
to. Empty means match all taint keys. If the key is empty,
operator must be Exists; this combination means to match
all values and all keys.
type: string
operator:
description: Operator represents a key's relationship to
the value. Valid operators are Exists and Equal. Defaults
to Equal. Exists is equivalent to wildcard for value,
so that a pod can tolerate all taints of a particular
category.
type: string
tolerationSeconds:
description: TolerationSeconds represents the period of
time the toleration (which must be of effect NoExecute,
otherwise this field is ignored) tolerates the taint.
By default, it is not set, which means tolerate the taint