Add a config item for novncproxy

In deployment-novncproxy.yaml, it set hostNetwork = true.
In some cases, we may want to let it use cluster network instead of
hostNetwork.
We'd better add a config item, so that client can override it to use
cluster network based on an operators preferences.

Story: 2006490
Task: 36439

Change-Id: Ia235d4e9542bd9242f9d2713ad1e67870f3016e2
Signed-off-by: zhipengl <zhipengs.liu@intel.com>
This commit is contained in:
zhipengl 2019-09-04 19:36:31 +08:00 committed by zhipeng liu
parent a326c8b448
commit 494212423a
2 changed files with 4 additions and 0 deletions

View File

@ -52,8 +52,10 @@ spec:
{{ tuple $envAll "nova" "novnc-proxy" | include "helm-toolkit.snippets.kubernetes_pod_anti_affinity" | indent 8 }} {{ tuple $envAll "nova" "novnc-proxy" | include "helm-toolkit.snippets.kubernetes_pod_anti_affinity" | indent 8 }}
nodeSelector: nodeSelector:
{{ .Values.labels.novncproxy.node_selector_key }}: {{ .Values.labels.novncproxy.node_selector_value }} {{ .Values.labels.novncproxy.node_selector_key }}: {{ .Values.labels.novncproxy.node_selector_value }}
{{- if .Values.pod.useHostNetwork.novncproxy }}
hostNetwork: true hostNetwork: true
dnsPolicy: ClusterFirstWithHostNet dnsPolicy: ClusterFirstWithHostNet
{{- end }}
initContainers: initContainers:
{{ tuple $envAll "novncproxy" $mounts_nova_novncproxy_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} {{ tuple $envAll "novncproxy" $mounts_nova_novncproxy_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }}
- name: nova-novncproxy-init - name: nova-novncproxy-init

View File

@ -2277,6 +2277,8 @@ pod:
nova_db_sync: nova_db_sync:
volumeMounts: volumeMounts:
volumes: volumes:
useHostNetwork:
novncproxy: true
replicas: replicas:
api_metadata: 1 api_metadata: 1
compute_ironic: 1 compute_ironic: 1