Skip to content
This repository has been archived by the owner on Jan 8, 2024. It is now read-only.

Commit

Permalink
Merge pull request #23 from axoflow/k8s-fields
Browse files Browse the repository at this point in the history
feat(k8s-source): add configurable fields for json paramaters
  • Loading branch information
kristofgyuracz authored Nov 23, 2023
2 parents ceab5ad + 45f2be0 commit 443a52b
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 1 deletion.
4 changes: 4 additions & 0 deletions charts/axosyslog-collector/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,3 +49,7 @@ The following table lists the configurable parameters of the AxoSyslog Collector
| tolerations | Tolerations for pod assignment | [] |
| affinity | Pod affinity | {} |
| updateStrategy | Update strategy for the DaemonSet | RollingUpdate |
| kubernetes.enabled | Enable kubernetes log collection | true |
| kubernetes.prefix | Set JSON prefix for logs collected from the k8s cluster | "" |
| kubernetes.keyDelimiter | Set JSON key delimiter for logs collected from the k8s cluster | "" |

9 changes: 8 additions & 1 deletion charts/axosyslog-collector/templates/config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,14 @@ data:
log {
{{- if .Values.config.sources.kubernetes.enabled }}
source { kubernetes(); };
source { kubernetes(
{{- if .Values.config.sources.kubernetes.prefix }}
prefix({{ .Values.config.sources.kubernetes.prefix | quote }})
{{- end }}
{{- if .Values.config.sources.kubernetes.keyDelimiter }}
key-delimiter({{ .Values.config.sources.kubernetes.keyDelimiter | quote }})
{{- end }}
); };
{{- end }}
{{- range .Values.config.sources.opentelemetry }}
source {
Expand Down
3 changes: 3 additions & 0 deletions charts/axosyslog-collector/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,9 @@ config:
sources:
kubernetes:
enabled: true
# E.g.:
# prefix: "k8s~"
# keyDelimiter: "~"
opentelemetry: []
# E.g.:
# - port: 4317
Expand Down

0 comments on commit 443a52b

Please sign in to comment.