@@ -4,7 +4,7 @@ apiVersion: apiextensions.k8s.io/v1
4
4
kind : CustomResourceDefinition
5
5
metadata :
6
6
annotations :
7
- controller-gen.kubebuilder.io/version : v0.17.1
7
+ controller-gen.kubebuilder.io/version : v0.17.2
8
8
name : ec2nodeclasses.karpenter.k8s.aws
9
9
spec :
10
10
group : karpenter.k8s.aws
@@ -237,6 +237,39 @@ spec:
237
237
x-kubernetes-validations :
238
238
- message : must have only one blockDeviceMappings with rootVolume
239
239
rule : self.filter(x, has(x.rootVolume)?x.rootVolume==true:false).size() <= 1
240
+ capacityReservationSelectorTerms :
241
+ description : |-
242
+ CapacityReservationSelectorTerms is a list of capacity reservation selector terms. Each term is ORed together to
243
+ determine the set of eligible capacity reservations.
244
+ items :
245
+ properties :
246
+ id :
247
+ description : ID is the capacity reservation id in EC2
248
+ pattern : ^cr-[0-9a-z]+$
249
+ type : string
250
+ ownerID :
251
+ description : Owner is the owner id for the ami.
252
+ pattern : ^[0-9]{12}$
253
+ type : string
254
+ tags :
255
+ additionalProperties :
256
+ type : string
257
+ description : |-
258
+ Tags is a map of key/value tags used to select capacity reservations.
259
+ Specifying '*' for a value selects all values for a given tag key.
260
+ maxProperties : 20
261
+ type : object
262
+ x-kubernetes-validations :
263
+ - message : empty tag keys or values aren't supported
264
+ rule : self.all(k, k != '' && self[k] != '')
265
+ type : object
266
+ maxItems : 30
267
+ type : array
268
+ x-kubernetes-validations :
269
+ - message : expected at least one, got none, ['tags', 'id']
270
+ rule : self.all(x, has(x.tags) || has(x.id))
271
+ - message : ' '' id'' is mutually exclusive, cannot be set along with tags in a capacity reservation selector term'
272
+ rule : ' !self.all(x, has(x.id) && (has(x.tags) || has(x.ownerID)))'
240
273
context :
241
274
description : |-
242
275
Context is a Reserved field in EC2 APIs
@@ -467,7 +500,7 @@ spec:
467
500
- message : immutable field changed
468
501
rule : self == oldSelf
469
502
securityGroupSelectorTerms :
470
- description : SecurityGroupSelectorTerms is a list of or security group selector terms. The terms are ORed.
503
+ description : SecurityGroupSelectorTerms is a list of security group selector terms. The terms are ORed.
471
504
items :
472
505
description : |-
473
506
SecurityGroupSelectorTerm defines selection logic for a security group used by Karpenter to launch nodes.
@@ -501,12 +534,12 @@ spec:
501
534
rule : self.size() != 0
502
535
- message : expected at least one, got none, ['tags', 'id', 'name']
503
536
rule : self.all(x, has(x.tags) || has(x.id) || has(x.name))
504
- - message : ' '' id'' is mutually exclusive, cannot be set with a combination of other fields in securityGroupSelectorTerms '
537
+ - message : ' '' id'' is mutually exclusive, cannot be set with a combination of other fields in a security group selector term '
505
538
rule : ' !self.all(x, has(x.id) && (has(x.tags) || has(x.name)))'
506
- - message : ' '' name'' is mutually exclusive, cannot be set with a combination of other fields in securityGroupSelectorTerms '
539
+ - message : ' '' name'' is mutually exclusive, cannot be set with a combination of other fields in a security group selector term '
507
540
rule : ' !self.all(x, has(x.name) && (has(x.tags) || has(x.id)))'
508
541
subnetSelectorTerms :
509
- description : SubnetSelectorTerms is a list of or subnet selector terms. The terms are ORed.
542
+ description : SubnetSelectorTerms is a list of subnet selector terms. The terms are ORed.
510
543
items :
511
544
description : |-
512
545
SubnetSelectorTerm defines selection logic for a subnet used by Karpenter to launch nodes.
@@ -535,7 +568,7 @@ spec:
535
568
rule : self.size() != 0
536
569
- message : expected at least one, got none, ['tags', 'id']
537
570
rule : self.all(x, has(x.tags) || has(x.id))
538
- - message : ' '' id'' is mutually exclusive, cannot be set with a combination of other fields in subnetSelectorTerms '
571
+ - message : ' '' id'' is mutually exclusive, cannot be set with a combination of other fields in a subnet selector term '
539
572
rule : ' !self.all(x, has(x.id) && has(x.tags))'
540
573
tags :
541
574
additionalProperties :
@@ -638,6 +671,46 @@ spec:
638
671
- requirements
639
672
type : object
640
673
type : array
674
+ capacityReservations :
675
+ description : |-
676
+ CapacityReservations contains the current capacity reservation values that are available to this NodeClass under the
677
+ CapacityReservation selectors.
678
+ items :
679
+ properties :
680
+ availabilityZone :
681
+ description : The availability zone the capacity reservation is available in.
682
+ type : string
683
+ endTime :
684
+ description : |-
685
+ The time at which the capacity reservation expires. Once expired, the reserved capacity is released and Karpenter
686
+ will no longer be able to launch instances into that reservation.
687
+ format : date-time
688
+ type : string
689
+ id :
690
+ description : The id for the capacity reservation.
691
+ pattern : ^cr-[0-9a-z]+$
692
+ type : string
693
+ instanceMatchCriteria :
694
+ description : Indicates the type of instance launches the capacity reservation accepts.
695
+ enum :
696
+ - open
697
+ - targeted
698
+ type : string
699
+ instanceType :
700
+ description : The instance type for the capacity reservation.
701
+ type : string
702
+ ownerID :
703
+ description : The ID of the AWS account that owns the capacity reservation.
704
+ pattern : ^[0-9]{12}$
705
+ type : string
706
+ required :
707
+ - availabilityZone
708
+ - id
709
+ - instanceMatchCriteria
710
+ - instanceType
711
+ - ownerID
712
+ type : object
713
+ type : array
641
714
conditions :
642
715
description : Conditions contains signals for health and readiness
643
716
items :
0 commit comments