diff --git a/charts/tsuru-prometheus-pool/Chart.yaml b/charts/tsuru-prometheus-pool/Chart.yaml index 36455fa..3e1d59e 100644 --- a/charts/tsuru-prometheus-pool/Chart.yaml +++ b/charts/tsuru-prometheus-pool/Chart.yaml @@ -15,7 +15,7 @@ type: application # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 0.2.6 +version: 0.2.7 # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. Versions are not expected to diff --git a/charts/tsuru-prometheus-pool/templates/networkpolicy.yaml b/charts/tsuru-prometheus-pool/templates/networkpolicy.yaml index beb9c66..61ac3aa 100644 --- a/charts/tsuru-prometheus-pool/templates/networkpolicy.yaml +++ b/charts/tsuru-prometheus-pool/templates/networkpolicy.yaml @@ -13,10 +13,10 @@ spec: name: tsuru-{{ .Values.tsuru.pool.name }} - ports: # allow egress to k8s-apiserver - - port: 80 - protocol: TCP - - port: 443 + {{- range $_, $port := .Values.networkPolicy.k8sAPIPorts }} + - port: {{ $port }} protocol: TCP + {{- end }} to: - namespaceSelector: matchLabels: diff --git a/charts/tsuru-prometheus-pool/values.yaml b/charts/tsuru-prometheus-pool/values.yaml index b83c426..ef02433 100644 --- a/charts/tsuru-prometheus-pool/values.yaml +++ b/charts/tsuru-prometheus-pool/values.yaml @@ -54,6 +54,7 @@ networkPolicy: enabled: true k8sAPIAddresses: [] # - IPs of k8s-apiserver + k8sAPIPorts: [80, 443] # additionalEgressRules: # - to: