Skip to content

Commit

Permalink
Add RBAC for publishing events, and env var for pod name
Browse files Browse the repository at this point in the history
  • Loading branch information
alpeb committed Dec 6, 2023
1 parent 1ca137a commit 0e943f4
Show file tree
Hide file tree
Showing 8 changed files with 64 additions and 8 deletions.
9 changes: 8 additions & 1 deletion charts/linkerd2-cni/templates/cni-plugin.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,9 @@ rules:
- apiGroups: [""]
resources: ["pods/eviction"]
verbs: ["create"]
- apiGroups: ["events.k8s.io"]
resources: ["events"]
verbs: ["create"]
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
Expand Down Expand Up @@ -286,10 +289,14 @@ spec:
imagePullPolicy: {{ .Values.reinitializePods.image.pullPolicy }}
{{- if .Values.reinitializePods.enableSecurityContext }}
env:
- name: LINKERD_REINITIALIZE_PODS_POD_NODE_NAME
- name: LINKERD_REINITIALIZE_PODS_NODE_NAME
valueFrom:
fieldRef:
fieldPath: spec.nodeName
- name: LINKERD_REINITIALIZE_PODS_POD_NAME
valueFrom:
fieldRef:
fieldPath: metadata.name
command:
- /usr/lib/linkerd/linkerd-reinitialize-pods
args:
Expand Down
9 changes: 8 additions & 1 deletion cli/cmd/testdata/install-cni-plugin_default.golden

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 8 additions & 1 deletion cli/cmd/testdata/install-cni-plugin_fully_configured.golden

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 8 additions & 1 deletion cli/cmd/testdata/install-cni-plugin_skip_ports.golden

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 8 additions & 1 deletion cli/cmd/testdata/install_cni_helm_default_output.golden

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 8 additions & 1 deletion cli/cmd/testdata/install_cni_helm_override_output.golden

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 0e943f4

Please sign in to comment.