Skip to content
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
8 changes: 8 additions & 0 deletions docs/pages/reference/helm-reference/teleport-kube-agent.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,14 @@ Cloud user, and manage your own version server.
You can override this to use your own Teleport Kube Agent Updater image rather
than a Teleport-published image.

### `updater.extraArgs`

| Type | Default value | Required? |
|--------|---------------|-----------|
| `list` | `[]` | No |

`extraArgs` contains additional arguments to pass to the updater binary.

## `roleBindingName`

| Type | Default value | Required? |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,9 @@ spec:
- "--base-image={{ include "teleport-kube-agent.baseImage" . }}"
- "--version-server={{ tpl $updater.versionServer . }}"
- "--version-channel={{ $updater.releaseChannel }}"
{{- if .Values.updater.extraArgs }}
{{- toYaml .Values.updater.extraArgs | nindent 10 }}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we add a snapshot to ensure the indentation is always ok?
I am now paranoid about that

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If indentation is not OK the contains test will properly fail as the item won't be in the list. The issue earlier was caused by the fact we did 2 rounds of dumping yaml/parsing yaml because of the config merge hack.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh you are correct

{{- end }}
{{- if $updater.securityContext }}
securityContext: {{- toYaml $updater.securityContext | nindent 10 }}
{{- end }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -235,3 +235,14 @@ tests:
- equal:
path: spec.template.spec.serviceAccountName
value: distinct-updater-sa
- it: sets extraArgs when set
values:
- ../.lint/updater.yaml
set:
updater:
extraArgs:
- "--foo=bar"
asserts:
- contains:
path: spec.template.spec.containers[0].args
content: "--foo=bar"
3 changes: 3 additions & 0 deletions examples/chart/teleport-kube-agent/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,9 @@ updater:
serviceAccount:
# service account name defaults to "<kube agent sa name>-updater"
name: ""
# extraArgs(list) -- contains additional arguments to pass to the updater
# binary.
extraArgs: []

# If set, will use an existing volume mounted via extraVolumes
# as the Teleport data directory.
Expand Down