Skip to content

Commit

Permalink
Create networkpolicy.yaml
Browse files Browse the repository at this point in the history
  • Loading branch information
itscaro committed Aug 31, 2022
1 parent c8eb057 commit 9f3da2b
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 1 deletion.
2 changes: 1 addition & 1 deletion helm/akhq/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v1
appVersion: "0.22.0"
description: Kafka GUI for Apache Kafka to manage topics, topics data, consumers group, schema registry, connect and more...
name: akhq
version: 0.2.9
version: 0.3.0
keywords:
- kafka
- confluent
Expand Down
25 changes: 25 additions & 0 deletions helm/akhq/templates/networkpolicy.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{{- if .Values.networkPolicy.enabled -}}
apiVersion: {{ template "networkPolicy.apiVersion" . }}
kind: NetworkPolicy
metadata:
name: {{ include "akhq.fullname" . }}
labels:
app.kubernetes.io/name: {{ include "akhq.name" . }}
helm.sh/chart: {{ include "akhq.chart" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
app.kubernetes.io/managed-by: {{ .Release.Service }}
{{- with .Values.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
policyTypes:
- Ingress
podSelector:
matchLabels:
app.kubernetes.io/name: {{ include "akhq.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
ingress:
- ports:
- port: http
- port: management
{{- end }}
3 changes: 3 additions & 0 deletions helm/akhq/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -143,3 +143,6 @@ nodeSelector: {}
tolerations: []

affinity: {}

networkPolicy:
enabled: true

0 comments on commit 9f3da2b

Please sign in to comment.