File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 7373 - podSelector :
7474 matchLabels :
7575 {{ template "flink.jobmanager.fullname" . }}-client: "true"
76+ {{- if .Values.jobmanager.networkPolicy.allowCurrentNamespace }}
77+ - namespaceSelector :
78+ matchLabels :
79+ kubernetes.io/metadata.name : {{ .Release.Namespace }}
80+ {{- end }}
81+ {{- range $namespace := .Values.jobmanager.networkPolicy.allowNamespaces }}
82+ {{- if $namespace }}
83+ - namespaceSelector :
84+ matchLabels :
85+ kubernetes.io/metadata.name : {{ $namespace }}
86+ {{- end }}
87+ {{- end }}
7688 {{- if .Values.jobmanager.networkPolicy.ingressNSMatchLabels }}
7789 - namespaceSelector :
7890 matchLabels :
Original file line number Diff line number Diff line change 11{{- /*
2- Copyright VMware, Inc .
2+ Copyright Drycc Community .
33SPDX-License-Identifier : APACHE-2.0
44*/}}
55
Original file line number Diff line number Diff line change 11{{- /*
2- Copyright VMware, Inc .
2+ Copyright Drycc Community .
33SPDX-License-Identifier : APACHE-2.0
44*/}}
55
4949 - ports :
5050 - port : {{ .Values.taskmanager.containerPorts.data }}
5151 - port : {{ .Values.taskmanager.containerPorts.rpc }}
52+ - port : {{ .Values.taskmanager.containerPorts.internalMetrics }}
5253 to :
5354 - podSelector :
5455 matchLabels : {{- include "common.labels.matchLabels" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 14 }}
@@ -62,16 +63,25 @@ spec:
6263 {{- if eq .Values.taskmanager.service.type "LoadBalancer" }}
6364 - {}
6465 {{- else }}
65- - ports :
66- - port : {{ .Values.taskmanager.containerPorts.data }}
67- - port : {{ .Values.taskmanager.containerPorts.rpc }}
68- {{- if not .Values.taskmanager.networkPolicy.allowExternal }}
69- from :
66+ - from :
67+ {{- if not .Values.taskmanager.networkPolicy.allowExternal }}
7068 - podSelector :
7169 matchLabels : {{- include "common.labels.matchLabels" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 14 }}
7270 - podSelector :
7371 matchLabels :
7472 {{ template "flink.taskmanager.fullname" . }}-client: "true"
73+ {{- if .Values.taskmanager.networkPolicy.allowCurrentNamespace }}
74+ - namespaceSelector :
75+ matchLabels :
76+ kubernetes.io/metadata.name : {{ .Release.Namespace }}
77+ {{- end }}
78+ {{- range $namespace := .Values.taskmanager.networkPolicy.allowNamespaces }}
79+ {{- if $namespace }}
80+ - namespaceSelector :
81+ matchLabels :
82+ kubernetes.io/metadata.name : {{ $namespace }}
83+ {{- end }}
84+ {{- end }}
7585 {{- if .Values.taskmanager.networkPolicy.ingressNSMatchLabels }}
7686 - namespaceSelector :
7787 matchLabels :
Original file line number Diff line number Diff line change 11{{- /*
2- Copyright VMware, Inc .
2+ Copyright Drycc Community .
33SPDX-License-Identifier : APACHE-2.0
44*/}}
55
Original file line number Diff line number Diff line change @@ -303,10 +303,12 @@ jobmanager:
303303 # # on. When true, server will accept connections from any source
304304 # # (with the correct destination port).
305305 # #
306- allowExternal : true
306+ allowExternal : false
307307 # # @param jobmanager.networkPolicy.allowExternalEgress Allow the pod to access any range of port and all destinations.
308308 # #
309309 allowExternalEgress : true
310+ allowCurrentNamespace : true
311+ allowNamespaces : []
310312 # # @param jobmanager.networkPolicy.extraIngress [array] Add extra ingress rules to the NetworkPolice
311313 # # e.g:
312314 # # extraIngress:
@@ -672,10 +674,12 @@ taskmanager:
672674 # # on. When true, server will accept connections from any source
673675 # # (with the correct destination port).
674676 # #
675- allowExternal : true
677+ allowExternal : false
676678 # # @param taskmanager.networkPolicy.allowExternalEgress Allow the pod to access any range of port and all destinations.
677679 # #
678680 allowExternalEgress : true
681+ allowCurrentNamespace : true
682+ allowNamespaces : []
679683 # # @param taskmanager.networkPolicy.extraIngress [array] Add extra ingress rules to the NetworkPolice
680684 # # e.g:
681685 # # extraIngress:
Original file line number Diff line number Diff line change @@ -18,12 +18,18 @@ allow_parameters:
1818- name : " jobmanager.service.type"
1919 required : false
2020 description : " jobmanager service type config for values.yaml"
21+ - name : " jobmanager.networkPolicy.allowNamespaces"
22+ required : false
23+ description : " jobmanager networkPolicy allowNamespaces config for values.yaml"
2124- name : " jobmanager.extraEnvVars"
2225 required : false
2326 description : " jobmanager extraEnvVars config for values.yaml"
2427- name : " taskmanager.service.type"
2528 required : false
2629 description : " taskmanager service type config for values.yaml"
30+ - name : " taskmanager.networkPolicy.allowNamespaces"
31+ required : false
32+ description : " taskmanager networkPolicy allowNamespaces config for values.yaml"
2733- name : " taskmanager.extraEnvVars"
2834 required : false
2935 description : " taskmanager extraEnvVars config for values.yaml"
You can’t perform that action at this time.
0 commit comments