Skip to content

Commit

Permalink
feat: Added value to suppress creation of ClusterRole and ClusterRole…
Browse files Browse the repository at this point in the history
…Bindung. If the value is not set, cluster roles will be created as before
  • Loading branch information
Matthias Klein committed Feb 26, 2024
1 parent da4a602 commit fd96b24
Show file tree
Hide file tree
Showing 8 changed files with 20 additions and 4 deletions.
2 changes: 1 addition & 1 deletion charts/eks/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ Whether to create a cluster role or not
.Values.proxy.metricsServer.nodes.enabled
.Values.multiNamespaceMode.enabled
.Values.coredns.plugin.enabled -}}
{{- true -}}
{{- .Values.suppressClusterRoleCreation | ternary "" "true" -}}
{{- end -}}
{{- end -}}

Expand Down
4 changes: 4 additions & 0 deletions charts/eks/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -333,6 +333,10 @@ serviceAccount:
# imagePullSecrets:
# - name: my-pull-secret

# Prevent Creation of ClusterRole and ClusterRoleBinding by setting this to true. If
# not set or false, a ClusterRole and ClsterRoleBinding will be created if needed
suppressClusterRoleCreation: false

# Service account that should be used by the pods synced by vcluster
workloadServiceAccount:
# This is not supported in multi-namespace mode
Expand Down
2 changes: 1 addition & 1 deletion charts/k0s/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ Whether to create a cluster role or not
.Values.proxy.metricsServer.nodes.enabled
.Values.multiNamespaceMode.enabled
.Values.coredns.plugin.enabled -}}
{{- true -}}
{{- .Values.suppressClusterRoleCreation | ternary "" "true" -}}
{{- end -}}
{{- end -}}

Expand Down
4 changes: 4 additions & 0 deletions charts/k0s/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -215,6 +215,10 @@ serviceAccount:
# imagePullSecrets:
# - name: my-pull-secret

# Prevent Creation of ClusterRole and ClusterRoleBinding by setting this to true. If
# not set or false, a ClusterRole and ClusterRoleBinding will be created if needed
suppressClusterRoleCreation: false

# Service account that should be used by the pods synced by vcluster
workloadServiceAccount:
# This is not supported in multi-namespace mode
Expand Down
2 changes: 1 addition & 1 deletion charts/k3s/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ Whether to create a cluster role or not
.Values.proxy.metricsServer.nodes.enabled
.Values.multiNamespaceMode.enabled
.Values.coredns.plugin.enabled -}}
{{- true -}}
{{- .Values.suppressClusterRoleCreation | ternary "" "true" -}}
{{- end -}}
{{- end -}}

Expand Down
4 changes: 4 additions & 0 deletions charts/k3s/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -235,6 +235,10 @@ serviceAccount:
# imagePullSecrets:
# - name: my-pull-secret

# Prevent Creation of ClusterRole and ClusterRoleBinding by setting this to true. If
# not set or false, a ClusterRole and ClusterRoleBinding will be created if needed
suppressClusterRoleCreation: false

# Service account that should be used by the pods synced by vcluster
workloadServiceAccount:
# This is not supported in multi-namespace mode
Expand Down
2 changes: 1 addition & 1 deletion charts/k8s/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ Whether to create a cluster role or not
.Values.proxy.metricsServer.nodes.enabled
.Values.multiNamespaceMode.enabled
.Values.coredns.plugin.enabled -}}
{{- true -}}
{{- .Values.suppressClusterRoleCreation | ternary "" "true" -}}
{{- end -}}
{{- end -}}

Expand Down
4 changes: 4 additions & 0 deletions charts/k8s/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -271,6 +271,10 @@ serviceAccount:
# imagePullSecrets:
# - name: my-pull-secret

# Prevent Creation of ClusterRole and ClusterRoleBinding by setting this to true. If
# not set or false, a ClusterRole and ClsterRoleBinding will be created if needed
suppressClusterRoleCreation: false

# Service account that should be used by the pods synced by vcluster
workloadServiceAccount:
# This is not supported in multi-namespace mode
Expand Down

0 comments on commit fd96b24

Please sign in to comment.