Skip to content

Commit 4cb7510

Browse files
authored
Merge pull request #2000 from M00nF1sh/main_crd
Update Installation manifests (CRD/Webhook/Controller)
2 parents 1ff609d + 6223bc8 commit 4cb7510

19 files changed

+224
-269
lines changed

Makefile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# Image URL to use all building/pushing image targets
33
IMG ?= amazon/aws-alb-ingress-controller:v2.1.3
44

5-
CRD_OPTIONS ?= "crd:trivialVersions=false,crdVersions=v1beta1"
5+
CRD_OPTIONS ?= "crd:crdVersions=v1"
66

77
# Get the currently used golang install path (in GOPATH/bin, unless GOBIN is set)
88
ifeq (,$(shell go env GOBIN))
@@ -41,7 +41,7 @@ deploy: manifests
4141
# Generate manifests e.g. CRD, RBAC etc.
4242
manifests: controller-gen
4343
$(CONTROLLER_GEN) $(CRD_OPTIONS) rbac:roleName=controller-role webhook paths="./..." output:crd:artifacts:config=config/crd/bases
44-
yq eval '.metadata.name = "webhook"' -i config/webhook/manifests.v1beta1.yaml
44+
yq eval '.metadata.name = "webhook"' -i config/webhook/manifests.yaml
4545

4646
# Run go fmt against code
4747
fmt:
@@ -71,7 +71,7 @@ ifeq (, $(shell which controller-gen))
7171
CONTROLLER_GEN_TMP_DIR=$$(mktemp -d) ;\
7272
cd $$CONTROLLER_GEN_TMP_DIR ;\
7373
go mod init tmp ;\
74-
go install sigs.k8s.io/controller-tools/cmd/controller-gen@v0.4.0 ;\
74+
go install sigs.k8s.io/controller-tools/cmd/controller-gen@v0.5.0 ;\
7575
rm -rf $$CONTROLLER_GEN_TMP_DIR ;\
7676
}
7777
CONTROLLER_GEN=$(GOBIN)/controller-gen

apis/elbv2/v1alpha1/targetgroupbinding_types.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,6 @@ type TargetGroupBindingStatus struct {
129129
}
130130

131131
// +kubebuilder:object:root=true
132-
// +kubebuilder:resource:categories=all
133132
// +kubebuilder:subresource:status
134133
// +kubebuilder:printcolumn:name="SERVICE-NAME",type="string",JSONPath=".spec.serviceRef.name",description="The Kubernetes Service's name"
135134
// +kubebuilder:printcolumn:name="SERVICE-PORT",type="string",JSONPath=".spec.serviceRef.port",description="The Kubernetes Service's port"

apis/elbv2/v1beta1/ingressclassparams_types.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,10 @@ type IngressClassParamsSpec struct {
8282
// +kubebuilder:object:root=true
8383
// +kubebuilder:resource:scope=Cluster
8484
// +kubebuilder:storageversion
85+
// +kubebuilder:printcolumn:name="GROUP-NAME",type="string",JSONPath=".spec.group.name",description="The Ingress Group name"
86+
// +kubebuilder:printcolumn:name="SCHEME",type="string",JSONPath=".spec.scheme",description="The AWS Load Balancer scheme"
87+
// +kubebuilder:printcolumn:name="IP-ADDRESS-TYPE",type="string",JSONPath=".spec.ipAddressType",description="The AWS Load Balancer ipAddressType"
88+
// +kubebuilder:printcolumn:name="AGE",type="date",JSONPath=".metadata.creationTimestamp"
8589
// IngressClassParams is the Schema for the IngressClassParams API
8690
type IngressClassParams struct {
8791
metav1.TypeMeta `json:",inline"`

apis/elbv2/v1beta1/targetgroupbinding_types.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,6 @@ type TargetGroupBindingStatus struct {
141141
}
142142

143143
// +kubebuilder:object:root=true
144-
// +kubebuilder:resource:categories=all
145144
// +kubebuilder:subresource:status
146145
// +kubebuilder:storageversion
147146
// +kubebuilder:printcolumn:name="SERVICE-NAME",type="string",JSONPath=".spec.serviceRef.name",description="The Kubernetes Service's name"

config/controller/controller.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,4 +43,5 @@ spec:
4343
initialDelaySeconds: 30
4444
timeoutSeconds: 10
4545
terminationGracePeriodSeconds: 10
46+
priorityClassName: system-cluster-critical
4647
serviceAccountName: controller

config/crd/bases/elbv2.k8s.aws_ingressclassparams.yaml

Lines changed: 101 additions & 108 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11

22
---
3-
apiVersion: apiextensions.k8s.io/v1beta1
3+
apiVersion: apiextensions.k8s.io/v1
44
kind: CustomResourceDefinition
55
metadata:
66
annotations:
7-
controller-gen.kubebuilder.io/version: v0.4.0
7+
controller-gen.kubebuilder.io/version: v0.5.0
88
creationTimestamp: null
99
name: ingressclassparams.elbv2.k8s.aws
1010
spec:
@@ -15,118 +15,111 @@ spec:
1515
plural: ingressclassparams
1616
singular: ingressclassparams
1717
scope: Cluster
18-
validation:
19-
openAPIV3Schema:
20-
description: IngressClassParams is the Schema for the IngressClassParams API
21-
properties:
22-
apiVersion:
23-
description: 'APIVersion defines the versioned schema of this representation
24-
of an object. Servers should convert recognized schemas to the latest
25-
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
26-
type: string
27-
kind:
28-
description: 'Kind is a string value representing the REST resource this
29-
object represents. Servers may infer this from the endpoint the client
30-
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
31-
type: string
32-
metadata:
33-
type: object
34-
spec:
35-
description: IngressClassParamsSpec defines the desired state of IngressClassParams
36-
properties:
37-
group:
38-
description: Group defines the IngressGroup for all Ingresses that belong
39-
to IngressClass with this IngressClassParams.
40-
properties:
41-
name:
42-
description: Name is the name of IngressGroup.
43-
type: string
44-
required:
45-
- name
46-
type: object
47-
ipAddressType:
48-
description: IPAddressType defines the ip address type for all Ingresses
49-
that belong to IngressClass with this IngressClassParams.
50-
enum:
51-
- ipv4
52-
- dualstack
53-
type: string
54-
namespaceSelector:
55-
description: NamespaceSelector restrict the namespaces of Ingresses
56-
that are allowed to specify the IngressClass with this IngressClassParams.
57-
* if absent or present but empty, it selects all namespaces.
58-
properties:
59-
matchExpressions:
60-
description: matchExpressions is a list of label selector requirements.
61-
The requirements are ANDed.
62-
items:
63-
description: A label selector requirement is a selector that contains
64-
values, a key, and an operator that relates the key and values.
65-
properties:
66-
key:
67-
description: key is the label key that the selector applies
68-
to.
69-
type: string
70-
operator:
71-
description: operator represents a key's relationship to a
72-
set of values. Valid operators are In, NotIn, Exists and
73-
DoesNotExist.
74-
type: string
75-
values:
76-
description: values is an array of string values. If the operator
77-
is In or NotIn, the values array must be non-empty. If the
78-
operator is Exists or DoesNotExist, the values array must
79-
be empty. This array is replaced during a strategic merge
80-
patch.
81-
items:
82-
type: string
83-
type: array
84-
required:
85-
- key
86-
- operator
87-
type: object
88-
type: array
89-
matchLabels:
90-
additionalProperties:
91-
type: string
92-
description: matchLabels is a map of {key,value} pairs. A single
93-
{key,value} in the matchLabels map is equivalent to an element
94-
of matchExpressions, whose key field is "key", the operator is
95-
"In", and the values array contains only "value". The requirements
96-
are ANDed.
97-
type: object
98-
type: object
99-
scheme:
100-
description: Scheme defines the scheme for all Ingresses that belong
101-
to IngressClass with this IngressClassParams.
102-
enum:
103-
- internal
104-
- internet-facing
105-
type: string
106-
tags:
107-
description: Tags defines list of Tags on AWS resources provisioned
108-
for Ingresses that belong to IngressClass with this IngressClassParams.
109-
items:
110-
description: Tag defines a AWS Tag on resources.
18+
versions:
19+
- additionalPrinterColumns:
20+
- description: The Ingress Group name
21+
jsonPath: .spec.group.name
22+
name: GROUP-NAME
23+
type: string
24+
- description: The AWS Load Balancer scheme
25+
jsonPath: .spec.scheme
26+
name: SCHEME
27+
type: string
28+
- description: The AWS Load Balancer ipAddressType
29+
jsonPath: .spec.ipAddressType
30+
name: IP-ADDRESS-TYPE
31+
type: string
32+
- jsonPath: .metadata.creationTimestamp
33+
name: AGE
34+
type: date
35+
name: v1beta1
36+
schema:
37+
openAPIV3Schema:
38+
description: IngressClassParams is the Schema for the IngressClassParams API
39+
properties:
40+
apiVersion:
41+
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'
42+
type: string
43+
kind:
44+
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'
45+
type: string
46+
metadata:
47+
type: object
48+
spec:
49+
description: IngressClassParamsSpec defines the desired state of IngressClassParams
50+
properties:
51+
group:
52+
description: Group defines the IngressGroup for all Ingresses that belong to IngressClass with this IngressClassParams.
11153
properties:
112-
key:
113-
description: The key of the tag.
114-
type: string
115-
value:
116-
description: The value of the tag.
54+
name:
55+
description: Name is the name of IngressGroup.
11756
type: string
11857
required:
119-
- key
120-
- value
58+
- name
12159
type: object
122-
type: array
123-
type: object
124-
type: object
125-
version: v1beta1
126-
versions:
127-
- name: v1beta1
60+
ipAddressType:
61+
description: IPAddressType defines the ip address type for all Ingresses that belong to IngressClass with this IngressClassParams.
62+
enum:
63+
- ipv4
64+
- dualstack
65+
type: string
66+
namespaceSelector:
67+
description: NamespaceSelector restrict the namespaces of Ingresses that are allowed to specify the IngressClass with this IngressClassParams. * if absent or present but empty, it selects all namespaces.
68+
properties:
69+
matchExpressions:
70+
description: matchExpressions is a list of label selector requirements. The requirements are ANDed.
71+
items:
72+
description: A label selector requirement is a selector that contains values, a key, and an operator that relates the key and values.
73+
properties:
74+
key:
75+
description: key is the label key that the selector applies to.
76+
type: string
77+
operator:
78+
description: operator represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist.
79+
type: string
80+
values:
81+
description: values is an array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. This array is replaced during a strategic merge patch.
82+
items:
83+
type: string
84+
type: array
85+
required:
86+
- key
87+
- operator
88+
type: object
89+
type: array
90+
matchLabels:
91+
additionalProperties:
92+
type: string
93+
description: matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed.
94+
type: object
95+
type: object
96+
scheme:
97+
description: Scheme defines the scheme for all Ingresses that belong to IngressClass with this IngressClassParams.
98+
enum:
99+
- internal
100+
- internet-facing
101+
type: string
102+
tags:
103+
description: Tags defines list of Tags on AWS resources provisioned for Ingresses that belong to IngressClass with this IngressClassParams.
104+
items:
105+
description: Tag defines a AWS Tag on resources.
106+
properties:
107+
key:
108+
description: The key of the tag.
109+
type: string
110+
value:
111+
description: The value of the tag.
112+
type: string
113+
required:
114+
- key
115+
- value
116+
type: object
117+
type: array
118+
type: object
119+
type: object
128120
served: true
129121
storage: true
122+
subresources: {}
130123
status:
131124
acceptedNames:
132125
kind: ""

0 commit comments

Comments
 (0)