diff --git a/CHANGELOG.md b/CHANGELOG.md index a57aea22d0fdf0767e2d1903bf3ed6ac6e8aa276..e2393f64d13ebcd085a1d311bfda2cac170c313e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## 9.2.6-bb.4 - 2021-03-22 + +Adding ability to specify istio gateways and hosts in values file + ## 9.2.6-bb.3 - 2021-03-16 Plugins have been preinstalled into the container and made available at registry.dso.mil. diff --git a/chart/Chart.yaml b/chart/Chart.yaml index 261b90494417214ee956e2ff0651079d2ea53b57..b06e400f9a8d6e28f35ab343999536e9b2814174 100644 --- a/chart/Chart.yaml +++ b/chart/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v1 appVersion: 8.6-community name: sonarqube description: SonarQube is an open sourced code quality scanning tool -version: 9.2.6-bb.3 +version: 9.2.6-bb.4 keywords: - coverage - security diff --git a/chart/templates/_helpers.tpl b/chart/templates/_helpers.tpl index 07d11932a54211c8fa1f0230b42ace0045096771..8059ff8c2ce3c005f62a79cac98fc74a883f9746 100644 --- a/chart/templates/_helpers.tpl +++ b/chart/templates/_helpers.tpl @@ -60,3 +60,10 @@ false true {{- end -}} {{- end -}} + +{{/* +Create chart name and version as used by the chart label. +*/}} +{{- define "sonarqube.chart" -}} +{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}} +{{- end -}} diff --git a/chart/templates/bigbang/virtualservice.yaml b/chart/templates/bigbang/virtualservice.yaml index 341c0c5fb5eb33f1501f52f1003fa6359878bfed..5c907c1f89d0cbe331b7bed0cf81c39472d02ba2 100644 --- a/chart/templates/bigbang/virtualservice.yaml +++ b/chart/templates/bigbang/virtualservice.yaml @@ -6,14 +6,19 @@ metadata: name: {{ template "sonarqube.fullname" . }} namespace: {{ .Release.Namespace }} labels: + helm.sh/chart: {{ include "sonarqube.chart" . }} app.kubernetes.io/instance: {{ .Release.Name }} app.kubernetes.io/managed-by: {{ .Release.Service }} app.kubernetes.io/part-of: sonarqube spec: gateways: - - istio-system/main + {{- range .Values.istio.sonarqube.gateways }} + - {{ . }} + {{- end }} hosts: - - "sonarqube.{{ .Values.hostname }}" + {{- range .Values.istio.sonarqube.hosts }} + - {{ tpl . $}} + {{- end }} http: - route: - destination: diff --git a/chart/values.yaml b/chart/values.yaml index 969404eb5a9bb09c954a92da4a860c5bdb8a612c..285f5bfda3b72e336fc2ab8c2cd346387e947f04 100644 --- a/chart/values.yaml +++ b/chart/values.yaml @@ -354,8 +354,19 @@ extraConfig: terminationGracePeriodSeconds: 60 # Big Bang Additions +## Your FQDN will be ${ .Values.subdomain }.${ .Values.hostname } hostname: bigbang.dev istio: - enabled: true + # Toggle istio integration + enabled: false + sonarqube: + # Toggle vs creation + enabled: true + annotations: {} + labels: {} + gateways: + - istio-system/main + hosts: + - sonarqube.{{ .Values.hostname }} monitoring: enabled: false diff --git a/tests/test-values.yml b/tests/test-values.yml index d5d2b8117db78ed870547e92d309c004e87e22c7..aaddc0cfbbe077fa397c2be1b467e11d09e6ff9a 100644 --- a/tests/test-values.yml +++ b/tests/test-values.yml @@ -3,4 +3,3 @@ image: istio: enabled: true -