Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't deploy PSPs for cluster versions >=1.24 #273

Merged
merged 2 commits into from
Aug 19, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions charts/external-dns-management/templates/clusterrole.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ rules:
- list
- update
- create
{{- if semverCompare "<1.24-0" .Capabilities.KubeVersion.GitVersion }}
- apiGroups:
- policy
resources:
Expand All @@ -78,6 +79,7 @@ rules:
- {{ include "external-dns-management.fullname" . }}
verbs:
- use
{{- end }}
- apiGroups:
- ""
resources:
Expand Down
2 changes: 2 additions & 0 deletions charts/external-dns-management/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,9 @@ spec:
template:
metadata:
annotations:
{{- if semverCompare "<1.24-0" .Capabilities.KubeVersion.GitVersion }}
checksum/psp: {{ include (print $.Template.BasePath "/psp.yaml") . | sha256sum }}
{{- end }}
{{- if .Values.configuration.serverPortHttp }}
prometheus.io/scrape: "true"
prometheus.io/port: "{{- .Values.configuration.serverPortHttp }}"
Expand Down
2 changes: 2 additions & 0 deletions charts/external-dns-management/templates/psp.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
{{- if semverCompare "<1.24-0" .Capabilities.KubeVersion.GitVersion }}
apiVersion: policy/v1beta1
kind: PodSecurityPolicy
metadata:
Expand Down Expand Up @@ -48,3 +49,4 @@ spec:
- min: 65534
max: 65534
readOnlyRootFilesystem: true
{{- end }}
4 changes: 3 additions & 1 deletion examples/controller-registration.yaml

Large diffs are not rendered by default.

Empty file.