Skip to content

Commit

Permalink
Merge pull request #72 from sp98/fix-clientProfileMapping-API
Browse files Browse the repository at this point in the history
Use list of BlockPoolMapping in clientProfileMappings spec
  • Loading branch information
nb-ohad authored Aug 1, 2024
2 parents c4c632a + 97f4625 commit e08591b
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 27 deletions.
2 changes: 1 addition & 1 deletion api/v1alpha1/clientprofilemapping_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ type BlockPoolMappingSpec struct {
// ClientProfileMappingSpec defines the desired state of ClientProfileMapping
type ClientProfileMappingSpec struct {
//+kubebuilder:validation:Optional
BlockPoolMapping *BlockPoolMappingSpec `json:"blockPoolMapping,omitempty"`
BlockPoolMapping []BlockPoolMappingSpec `json:"blockPoolMapping,omitempty"`
}

// ClientProfileMappingStatus defines the observed state of ClientProfileMapping
Expand Down
4 changes: 2 additions & 2 deletions api/v1alpha1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

50 changes: 26 additions & 24 deletions config/crd/bases/csi.ceph.io_clientprofilemappings.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,30 +41,32 @@ spec:
description: ClientProfileMappingSpec defines the desired state of ClientProfileMapping
properties:
blockPoolMapping:
description: BlockPoolMappingSpec define a mapiing between a local
and remote block pools
properties:
local:
description: BlockPoolRefSpec identify a blockpool - client profile
pair
properties:
clientProfileName:
type: string
poolId:
minimum: 0
type: integer
type: object
remote:
description: BlockPoolRefSpec identify a blockpool - client profile
pair
properties:
clientProfileName:
type: string
poolId:
minimum: 0
type: integer
type: object
type: object
items:
description: BlockPoolMappingSpec define a mapiing between a local
and remote block pools
properties:
local:
description: BlockPoolRefSpec identify a blockpool - client
profile pair
properties:
clientProfileName:
type: string
poolId:
minimum: 0
type: integer
type: object
remote:
description: BlockPoolRefSpec identify a blockpool - client
profile pair
properties:
clientProfileName:
type: string
poolId:
minimum: 0
type: integer
type: object
type: object
type: array
type: object
status:
description: ClientProfileMappingStatus defines the observed state of
Expand Down

0 comments on commit e08591b

Please sign in to comment.