Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added flg that can disable to ingress defaultBackend #1976

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions charts/vald-helm-operator/crds/valdrelease.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2022,6 +2022,11 @@ spec:
enum:
- glg
- zap
networkPolicy:
type: object
properties:
enabled:
type: boolean
observability:
type: object
properties:
Expand Down Expand Up @@ -4133,6 +4138,11 @@ spec:
annotations:
type: object
x-kubernetes-preserve-unknown-fields: true
defaultBackend:
type: object
properties:
enabled:
type: boolean
enabled:
type: boolean
host:
Expand Down Expand Up @@ -5287,6 +5297,11 @@ spec:
annotations:
type: object
x-kubernetes-preserve-unknown-fields: true
defaultBackend:
type: object
properties:
enabled:
type: boolean
enabled:
type: boolean
host:
Expand Down
2 changes: 2 additions & 0 deletions charts/vald/templates/gateway/filter/ing.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,12 @@ metadata:
app.kubernetes.io/component: gateway-filter
name: {{ $gateway.name }}-ingress
spec:
{{- if $gateway.ingress.defaultBackend.enabled }}
defaultBackend:
service:
name: {{ $gateway.name }}
{{- include "vald.ingressPort" (dict "Values" $gateway.ingress) | nindent 6 }}
{{- end }}
rules:
- host: {{ $gateway.ingress.host }}
http:
Expand Down
2 changes: 2 additions & 0 deletions charts/vald/templates/gateway/lb/ing.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,12 @@ metadata:
app.kubernetes.io/component: gateway-lb
name: {{ $gateway.name }}-ingress
spec:
{{- if $gateway.ingress.defaultBackend.enabled }}
defaultBackend:
service:
name: {{ $gateway.name }}
{{- include "vald.ingressPort" (dict "Values" $gateway.ingress) | nindent 6 }}
{{- end }}
rules:
- host: {{ $gateway.ingress.host }}
http:
Expand Down
29 changes: 29 additions & 0 deletions charts/vald/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -3275,6 +3275,15 @@
}
}
},
"networkPolicy": {
"type": "object",
"properties": {
"enabled": {
"type": "boolean",
"description": "if network policy enabled TODO: Change this to true after implementing user custom network policy parser"
}
}
},
"observability": {
"type": "object",
"properties": {
Expand Down Expand Up @@ -6829,6 +6838,16 @@
"type": "object",
"description": "annotations for ingress"
},
"defaultBackend": {
"type": "object",
"description": "defaultBackend config",
"properties": {
"enabled": {
"type": "boolean",
"description": "gateway ingress defaultBackend enabled"
}
}
},
"enabled": {
"type": "boolean",
"description": "gateway ingress enabled"
Expand Down Expand Up @@ -8767,6 +8786,16 @@
"type": "object",
"description": "annotations for ingress"
},
"defaultBackend": {
"type": "object",
"description": "defaultBackend config",
"properties": {
"enabled": {
"type": "boolean",
"description": "gateway ingress defaultBackend enabled"
}
}
},
"enabled": {
"type": "boolean",
"description": "gateway ingress enabled"
Expand Down
12 changes: 12 additions & 0 deletions charts/vald/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1076,6 +1076,12 @@ gateway:
# @schema {"name": "gateway.lb.ingress.servicePort", "type": "string"}
# gateway.lb.ingress.servicePort -- service port to be exposed by ingress
servicePort: grpc
# @schema {"name": "gateway.lb.ingress.defaultBackend", "type": "object"}
# gateway.lb.ingress.defaultBackend -- defaultBackend config
defaultBackend:
# @schema {"name": "gateway.lb.ingress.defaultBackend.enabled", "type": "boolean"}
# gateway.lb.ingress.defaultBackend.enabled -- gateway ingress defaultBackend enabled
enabled: true
# @schema {"name": "gateway.lb.resources", "type": "object", "anchor": "resources"}
# gateway.lb.resources -- compute resources
resources:
Expand Down Expand Up @@ -1344,6 +1350,12 @@ gateway:
# @schema {"name": "gateway.filter.ingress.servicePort", "type": "string"}
# gateway.filter.ingress.servicePort -- service port to be exposed by ingress
servicePort: grpc
# @schema {"name": "gateway.filter.ingress.defaultBackend", "type": "object"}
# gateway.filter.ingress.defaultBackend -- defaultBackend config
defaultBackend:
# @schema {"name": "gateway.filter.ingress.defaultBackend.enabled", "type": "boolean"}
# gateway.filter.ingress.defaultBackend.enabled -- gateway ingress defaultBackend enabled
enabled: true
# @schema {"name": "gateway.filter.resources", "type": "object", "anchor": "resources"}
# gateway.filter.resources -- compute resources
resources:
Expand Down