From: garciadeblas Date: Wed, 31 May 2023 21:47:01 +0000 (+0200) Subject: Update OSM helm chart to support installation behind HTTP proxy X-Git-Tag: release-v14.0-start~14 X-Git-Url: https://osm.etsi.org/gitweb/?a=commitdiff_plain;h=refs%2Fchanges%2F82%2F13482%2F4;p=osm%2Fdevops.git Update OSM helm chart to support installation behind HTTP proxy Change-Id: Ibd50b4fddcb205130935ab38369144637b68b5a6 Signed-off-by: garciadeblas --- diff --git a/installers/full_install_osm.sh b/installers/full_install_osm.sh index 8f092fb8..f110b9ac 100755 --- a/installers/full_install_osm.sh +++ b/installers/full_install_osm.sh @@ -322,6 +322,12 @@ EOF" [ -n "$OSM_VCA_APIPROXY" ] && OSM_HELM_OPTS="${OSM_HELM_OPTS} --set lcm.config.OSMLCM_VCA_APIPROXY=${OSM_VCA_APIPROXY}" [ ! "$OSM_DOCKER_TAG" == "13" ] && OSM_HELM_OPTS="${OSM_HELM_OPTS} --set global.image.tag=${OSM_DOCKER_TAG}" [ -n "${INSTALL_NGSA}" ] || OSM_HELM_OPTS="${OSM_HELM_OPTS} --set global.oldServiceAssurance=true" + if [ -n "${OSM_BEHIND_PROXY}" ]; then + OSM_HELM_OPTS="${OSM_HELM_OPTS} --set global.behindHttpProxy=true" + [ -n "${HTTP_PROXY}" ] && OSM_HELM_OPTS="${OSM_HELM_OPTS} --set global.httpProxy.HTTP_PROXY=${HTTP_PROXY}" + [ -n "${HTTPS_PROXY}" ] && OSM_HELM_OPTS="${OSM_HELM_OPTS} --set global.httpProxy.HTTPS_PROXY=${HTTPS_PROXY}" + [ -n "${NO_PROXY}" ] && OSM_HELM_OPTS="${OSM_HELM_OPTS} --set global.httpProxy.NO_PROXY=${NO_PROXY}" + fi echo "helm -n $OSM_NAMESPACE install $OSM_NAMESPACE $OSM_DEVOPS/installers/helm/osm -f ${OSM_HELM_WORK_DIR}/osm-values.yaml ${OSM_HELM_OPTS}" helm -n $OSM_NAMESPACE install $OSM_NAMESPACE $OSM_DEVOPS/installers/helm/osm -f ${OSM_HELM_WORK_DIR}/osm-values.yaml ${OSM_HELM_OPTS} diff --git a/installers/helm/osm/templates/lcm/lcm-configmap.yaml b/installers/helm/osm/templates/lcm/lcm-configmap.yaml index c976a701..9fdfcc8e 100644 --- a/installers/helm/osm/templates/lcm/lcm-configmap.yaml +++ b/installers/helm/osm/templates/lcm/lcm-configmap.yaml @@ -30,6 +30,11 @@ data: OSMLCM_STORAGE_COLLECTION: "files" OSMLCM_STORAGE_URI: "mongodb://mongodb-k8s:27017/?replicaSet=rs0" OSMLCM_GLOBAL_LOGLEVEL: {{ .Values.lcm.logLevel | default .Values.global.logLevel | default "INFO" }} +{{- if .Values.global.behindHttpProxy -}} +{{- with .Values.global.httpProxy }} + {{- . | toYaml | nindent 2 }} +{{- end }} +{{- end }} {{- with .Values.lcm.config }} {{- . | toYaml | nindent 2 }} {{- end }}