Files
wlan-cloud-helm/tip-wlan/charts/cassandra/templates/networkpolicy.yaml
Rahul Sharma 44c7772c2d TW-648, TW-650: Updated Cassandra to work in SSL mode
- Also updated SSC to work with Cassandra in SSL mode.
- Created Schema in Cassandra on SSC startup
2020-07-08 14:25:02 -04:00

39 lines
1.2 KiB
YAML

{{- if .Values.networkPolicy.enabled }}
kind: NetworkPolicy
apiVersion: {{ include "networkPolicy.apiVersion" . }}
metadata:
name: {{ include "common.fullname" . }}
namespace: {{ include "common.namespace" . }}
labels: {{- include "common.labels" . | nindent 4 }}
spec:
podSelector:
matchLabels: {{- include "common.selectorLabels" . | nindent 6 }}
ingress:
# Allow inbound connections
# CQL and Thrift ports
- ports:
- port: {{ .Values.service.port }}
- port: {{ .Values.service.thriftPort }}
from:
{{- if not .Values.networkPolicy.allowExternal }}
- podSelector:
matchLabels:
{{ include "common.fullname" . }}-client: "true"
{{- end }}
- podSelector:
matchLabels: {{- include "common.selectorLabels" . | nindent 14 }}
# Internal ports
- ports:
- port: intra
- port: tls
- port: jmx
from:
- podSelector:
matchLabels: {{- include "common.selectorLabels" . | nindent 14 }}
{{- if .Values.metrics.enabled }}
# Allow prometheus scrapes for metrics
- ports:
- port: 8080
{{- end }}
{{- end }}