X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=kubernetes%2Fcommon%2Fcommon%2Ftemplates%2F_ingress.tpl;h=30ef02295f4f2bf4531299f37ff2c9be210a9c1f;hb=eb68c405edd326112581ad901f1ce1d3d2e2b98b;hp=7065338cf9a24417b4b5ddf7829415a108b95d42;hpb=5c0678f7cc26241252692d84b4a31862c1204237;p=oom.git diff --git a/kubernetes/common/common/templates/_ingress.tpl b/kubernetes/common/common/templates/_ingress.tpl index 7065338cf9..30ef02295f 100644 --- a/kubernetes/common/common/templates/_ingress.tpl +++ b/kubernetes/common/common/templates/_ingress.tpl @@ -14,6 +14,21 @@ # See the License for the specific language governing permissions and # limitations under the License. */}} +{{/* + Helper function to check, if Ingress is globally enabled +*/}} +{{- define "common.ingressEnabled" -}} +{{- $dot := default . .dot -}} +{{- if $dot.Values.ingress -}} +{{- if $dot.Values.global.ingress -}} +{{- if (default false $dot.Values.global.ingress.enabled) -}} +true +{{- end -}} +{{- end -}} +{{- end -}} +{{- end -}} + + {{/* Create the hostname as concatination . - baseaddr: from component values: ingress.service.baseaddr