Skip to content

fix: security context and resources configurable for rbac proxy sidecar #25

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

Merged
merged 1 commit into from
Jun 5, 2023
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: 1 addition & 1 deletion chart/k8soauth2-proxy-controller/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,4 @@ keywords:
name: k8soauth2-proxy-controller
sources:
- https://github.com/DoodleScheduling/k8soauth2-proxy-controller
version: 0.2.3
version: 0.2.4
11 changes: 5 additions & 6 deletions chart/k8soauth2-proxy-controller/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -96,12 +96,9 @@ spec:
name: https
protocol: TCP
resources:
limits:
cpu: 500m
memory: 128Mi
requests:
cpu: 5m
memory: 64Mi
{{- toYaml .Values.kubeRBACProxy.resources | nindent 10 }}
securityContext:
{{- toYaml .Values.kubeRBACProxy.securityContext | nindent 10 }}
terminationMessagePath: /dev/termination-log
terminationMessagePolicy: File
{{- end }}
Expand All @@ -114,6 +111,8 @@ spec:
secret:
secretName: {{ .secretName }}
{{- end }}
securityContext:
{{- toYaml .Values.podSecurityContext | nindent 8 }}
affinity:
{{- toYaml .Values.affinity | nindent 8 }}
imagePullSecrets:
Expand Down
10 changes: 10 additions & 0 deletions chart/k8soauth2-proxy-controller/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,8 @@ securityContext:
capabilities:
drop: ["all"]
readOnlyRootFilesystem: true

podSecurityContext:
runAsGroup: 10000
runAsNonRoot: true
runAsUser: 10000
Expand Down Expand Up @@ -131,4 +133,12 @@ prometheusRule:
kubeRBACProxy:
enabled: true

securityContext:
allowPrivilegeEscalation: false
capabilities:
drop: ["all"]
readOnlyRootFilesystem: true

resources: {}

tolerations: []