Skip to content

Commit

Permalink
chore: Update nodeClassRef to be Group instead of APIVersion (#1360)
Browse files Browse the repository at this point in the history
  • Loading branch information
engedaam committed Jun 29, 2024
1 parent 51b7316 commit 6136cb2
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 8 deletions.
4 changes: 3 additions & 1 deletion kwok/charts/crds/karpenter.sh_nodeclaims.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ spec:
nodeClassRef:
description: NodeClassRef is a reference to an object that defines provider specific configuration
properties:
apiVersion:
group:
description: API version of the referent
type: string
kind:
Expand All @@ -85,6 +85,8 @@ spec:
description: 'Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names'
type: string
required:
- group
- kind
- name
type: object
requirements:
Expand Down
4 changes: 3 additions & 1 deletion kwok/charts/crds/karpenter.sh_nodepools.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ spec:
nodeClassRef:
description: NodeClassRef is a reference to an object that defines provider specific configuration
properties:
apiVersion:
group:
description: API version of the referent
type: string
kind:
Expand All @@ -206,6 +206,8 @@ spec:
description: 'Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names'
type: string
required:
- group
- kind
- name
type: object
requirements:
Expand Down
4 changes: 3 additions & 1 deletion pkg/apis/crds/karpenter.sh_nodeclaims.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ spec:
nodeClassRef:
description: NodeClassRef is a reference to an object that defines provider specific configuration
properties:
apiVersion:
group:
description: API version of the referent
type: string
kind:
Expand All @@ -85,6 +85,8 @@ spec:
description: 'Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names'
type: string
required:
- group
- kind
- name
type: object
requirements:
Expand Down
4 changes: 3 additions & 1 deletion pkg/apis/crds/karpenter.sh_nodepools.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ spec:
nodeClassRef:
description: NodeClassRef is a reference to an object that defines provider specific configuration
properties:
apiVersion:
group:
description: API version of the referent
type: string
kind:
Expand All @@ -206,6 +206,8 @@ spec:
description: 'Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names'
type: string
required:
- group
- kind
- name
type: object
requirements:
Expand Down
8 changes: 4 additions & 4 deletions pkg/apis/v1/nodeclaim.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,14 +70,14 @@ type ResourceRequirements struct {

type NodeClassReference struct {
// Kind of the referent; More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds"
// +optional
Kind string `json:"kind,omitempty"`
// +required
Kind string `json:"kind"`
// Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names
// +required
Name string `json:"name"`
// API version of the referent
// +optional
APIVersion string `json:"apiVersion,omitempty"`
// +required
Group string `json:"group"`
}

// +kubebuilder:object:generate=false
Expand Down

0 comments on commit 6136cb2

Please sign in to comment.