Skip to content

Commit 6c6b6d3

Browse files
Add envoy provisionerType & nodeSelector (#27)
Signed-off-by: Arnob kumar saha <[email protected]>
1 parent 5092b74 commit 6c6b6d3

File tree

3 files changed

+42
-4
lines changed

3 files changed

+42
-4
lines changed

api/gateway/v1alpha1/gatewayconfig_types.go

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -199,16 +199,30 @@ type ClusterTLS struct {
199199
}
200200

201201
type EnvoySpec struct {
202-
Image string `json:"image"`
203-
Tag string `json:"tag"`
202+
ProvisionerType ProvisionerType `json:"provisionerType"`
203+
Image string `json:"image"`
204+
Tag string `json:"tag"`
205+
//+optional
206+
NodeSelector map[string]string `json:"nodeSelector"`
204207
//+optional
205208
SecurityContext *core.SecurityContext `json:"securityContext"`
206209
Service EnvoyServiceSpec `json:"service"`
207210
}
208211

212+
// +kubebuilder:validation:Enum=Deployment;DaemonSet
213+
type ProvisionerType string
214+
215+
const (
216+
ProvisionerTypeDeployment ProvisionerType = "Deployment"
217+
ProvisionerTypeDaemonSet ProvisionerType = "DaemonSet"
218+
)
219+
209220
type EnvoyValues struct {
210-
Image string `json:"image"`
211-
Tag string `json:"tag"`
221+
ProvisionerType ProvisionerType `json:"provisionerType"`
222+
Image string `json:"image"`
223+
Tag string `json:"tag"`
224+
//+optional
225+
NodeSelector map[string]string `json:"nodeSelector"`
212226
//+optional
213227
SecurityContext *core.SecurityContext `json:"securityContext"`
214228
Service EnvoyServiceValues `json:"service"`

api/gateway/v1alpha1/zz_generated.deepcopy.go

Lines changed: 14 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

crds/gateway.catalog.appscode.com_gatewayconfigs.yaml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -322,6 +322,15 @@ spec:
322322
properties:
323323
image:
324324
type: string
325+
nodeSelector:
326+
additionalProperties:
327+
type: string
328+
type: object
329+
provisionerType:
330+
enum:
331+
- Deployment
332+
- DaemonSet
333+
type: string
325334
securityContext:
326335
description: |-
327336
SecurityContext holds security configuration that will be applied to a container.
@@ -559,6 +568,7 @@ spec:
559568
type: string
560569
required:
561570
- image
571+
- provisionerType
562572
- service
563573
- tag
564574
type: object

0 commit comments

Comments
 (0)