[incubator/buzzfeed-sso] Add support for GCP BackendConfig (#22148)

* Add support for GCP BackendConfig.

Signed-off-by: Anas <anas-aso@users.noreply.github.com>

* Bump chart version.

Signed-off-by: Anas <anas-aso@users.noreply.github.com>

* Document new variable.

Signed-off-by: Anas <anas-aso@users.noreply.github.com>
This commit is contained in:
Anas
2020-06-07 01:37:45 -07:00
committed by GitHub
parent fd82c27eb3
commit 80cf7057ce
5 changed files with 27 additions and 1 deletions
+1 -1
View File
@@ -1,7 +1,7 @@
apiVersion: v1
description: Single sign-on for your Kubernetes services using Google OAuth
name: buzzfeed-sso
version: 0.2.1
version: 0.2.2
appVersion: 2.1.0
home: https://github.com/buzzfeed/sso
sources:
+1
View File
@@ -95,6 +95,7 @@ Parameter | Description | Default
`ingress.extraLabels` | extra ingress labels | `{}`
`ingress.hosts` | proxied hosts | `[]`
`ingress.tls` | tls certificates for the proxied hosts | `[]`
`ingress.gcpBackendConfig` | GCP LB backend service configuration | `{}`
`upstreams` | configuration of services that use sso | `[]`
Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example,
@@ -0,0 +1,15 @@
{{- if and .Values.ingress.enabled .Values.ingress.gcpBackendConfig }}
apiVersion: cloud.google.com/v1beta1
kind: BackendConfig
metadata:
name: {{ template "buzzfeed-sso.fullname" . }}
labels:
app: {{ template "buzzfeed-sso.name" . }}
chart: {{ template "buzzfeed-sso.chart" . }}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
spec:
{{- with .Values.ingress.gcpBackendConfig }}
{{ toYaml . | indent 2 }}
{{- end }}
{{- end }}
@@ -9,6 +9,10 @@ metadata:
component: {{ $name }}-proxy
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
{{- if and .Values.ingress.enabled .Values.ingress.gcpBackendConfig }}
annotations:
beta.cloud.google.com/backend-config: '{"ports": {"http":"{{ template "buzzfeed-sso.fullname" . }}"}}'
{{- end }}
spec:
type: {{ .Values.proxy.service.type }}
ports:
+6
View File
@@ -101,6 +101,12 @@ ingress:
# - secretName: mybackend-mydomain-tls
# hosts:
# - mybackend.mydomain.foo
# GCP backend service configuration
# Possible values can be found here : https://cloud.google.com/kubernetes-engine/docs/concepts/backendconfig#backendconfigspec_v1beta1_cloudgooglecom
gcpBackendConfig: {}
# timeoutSec: 60
# connectionDraining:
# drainingTimeoutSec: 60
upstreams: []
# See https://github.com/buzzfeed/sso/blob/f437f237ac977201f15868601c9bc0e9dff11f40/docs/sso_config.md#proxy-config