Skip to content

Commit

Permalink
[core] Add Options to set Headers to VirtualService (#603)
Browse files Browse the repository at this point in the history
It is now possible to set headers to the VirtualServices created by the
Helm chart.
  • Loading branch information
ricoberger authored Nov 1, 2023
1 parent ed155d0 commit ee3bbe3
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 1 deletion.
2 changes: 1 addition & 1 deletion deploy/helm/kobs/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ apiVersion: v2
name: kobs
description: Kubernetes Observability Platform
type: application
version: 0.1.0
version: 0.2.0
appVersion: v0.12.0
4 changes: 4 additions & 0 deletions deploy/helm/kobs/templates/cluster/virtualservice.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,5 +26,9 @@ spec:
port:
number: 15221
timeout: {{ .Values.cluster.istio.virtualService.timeout }}
{{- with .Values.cluster.istio.virtualService.headers }}
headers:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- end }}
{{- end }}
4 changes: 4 additions & 0 deletions deploy/helm/kobs/templates/hub/virtualservice.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,5 +35,9 @@ spec:
port:
number: 15219
timeout: 60s
{{- with .Values.hub.istio.virtualService.headers }}
headers:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- end }}
{{- end }}
8 changes: 8 additions & 0 deletions deploy/helm/kobs/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -350,6 +350,10 @@ hub:

timeout: 300s

## Set, add or remove headers in the VirtualService.
##
headers: {}

## You can also add your own routes to the VirtualService.
##
additionalRoutes: []
Expand Down Expand Up @@ -775,6 +779,10 @@ cluster:

timeout: 300s

## Set, add or remove headers in the VirtualService.
##
headers: {}

## You can also add your own routes to the VirtualService.
##
additionalRoutes: []
Expand Down
2 changes: 2 additions & 0 deletions docs/getting-started/installation/helm.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ helm upgrade --install kobs kobs/kobs
| `hub.istio.virtualService.gateways` | A list of gateways for the VirtualService. | `[]` |
| `hub.istio.virtualService.hosts` | A list of hosts for the VirtualService. | `[]` |
| `hub.istio.virtualService.timeout` | Timeout for API requests. | `300s` |
| `hub.istio.virtualService.headers` | Modify the headers in the VirtualService. | `{}` |
| `hub.istio.virtualService.additionalRoutes` | A list of additional routes for the VirtualService. | `[]` |
| `hub.serviceMonitor.enabled` | Create a Service Monitor for kobs. | `false` |
| `hub.serviceMonitor.interval` | Interval at which metrics should be scraped. Fallback to the Prometheus default unless specified. | |
Expand Down Expand Up @@ -143,6 +144,7 @@ helm upgrade --install kobs kobs/kobs
| `cluster.istio.virtualService.gateways` | A list of gateways for the VirtualService. | `[]` |
| `cluster.istio.virtualService.hosts` | A list of hosts for the VirtualService. | `[]` |
| `cluster.istio.virtualService.timeout` | Timeout for API requests. | `300s` |
| `cluster.istio.virtualService.headers` | Modify the headers in the VirtualService. | `{}` |
| `cluster.istio.virtualService.additionalRoutes` | A list of additional routes for the VirtualService. | `[]` |
| `cluster.serviceMonitor.enabled` | Create a Service Monitor for kobs. | `false` |
| `cluster.serviceMonitor.interval` | Interval at which metrics should be scraped. Fallback to the Prometheus default unless specified. | |
Expand Down

0 comments on commit ee3bbe3

Please sign in to comment.