Skip to content

Commit

Permalink
feat(chart): Allow passing extra args to otel logs stateful set (#3076)
Browse files Browse the repository at this point in the history
* initial commit

* renaming change file

* added details in readme

* added default value of otel sts args

* fixed code styling

* setting blank extraArgs

* rebase main branch

* renaming change file

* added details in readme

* added default value of otel sts args

* fixed code styling

* setting blank extraArgs

* reveretd changefile
  • Loading branch information
rupeshnemade authored Jun 6, 2023
1 parent d41825f commit 7134ef4
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions .changelog/3076.changed.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
feat: pass extra arguments to otel logs statefulset
1 change: 1 addition & 0 deletions deploy/helm/sumologic/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -569,6 +569,7 @@ The following table lists the configurable parameters of the Sumo Logic chart an
| `metadata.logs.statefulset.extraVolumes` | Additional volumes for logs metadata enrichment (otelcol) pods. | `Nil` |
| `metadata.logs.statefulset.extraVolumeMounts` | Additional volume mounts for logs metadata enrichment (otelcol) pods. | `Nil` |
| `metadata.logs.statefulset.extraPorts` | Additional exposed ports in logs metadata enrichment (otelcol) pods and service. | `Nil` |
| `metadata.logs.statefulset.extraArgs` | Additional arguments to otelcol container. | `Nil` |
| `metadata.logs.autoscaling.enabled` | Option to turn autoscaling on for logs metadata enrichment (otelcol) and specify params for HPA. Autoscaling needs metrics-server to access cpu metrics. | `false` |
| `metadata.logs.autoscaling.minReplicas` | Default min replicas for autoscaling. | `3` |
| `metadata.logs.autoscaling.maxReplicas` | Default max replicas for autoscaling | `10` |
Expand Down
3 changes: 3 additions & 0 deletions deploy/helm/sumologic/templates/logs/otelcol/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,9 @@ spec:
imagePullPolicy: {{ .Values.metadata.image.pullPolicy }}
args:
- --config=/etc/otel/config.yaml
{{- if .Values.metadata.logs.statefulset.extraArgs }}
{{ toYaml .Values.metadata.logs.statefulset.extraArgs | indent 10 }}
{{- end }}
resources:
{{- toYaml .Values.metadata.logs.statefulset.resources | nindent 10 }}
{{- if .Values.metadata.logs.statefulset.containers.otelcol.securityContext }}
Expand Down
1 change: 1 addition & 0 deletions deploy/helm/sumologic/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4050,6 +4050,7 @@ metadata:
# - name: otlphttp2
# containerPort: 4319
# protocol: TCP
# extraArgs:

## Option to turn autoscaling on for logs and specify params for HPA.
## Autoscaling needs metrics-server to access cpu metrics.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,8 @@ metadata:
- name: otlphttp3
containerPort: 4320
protocol: TCP
extraArgs:
- --config=/etc/otel/test-config.yaml

## Option to turn autoscaling on for logs and specify params for HPA.
## Autoscaling needs metrics-server to access cpu metrics.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ spec:
imagePullPolicy: IfNotPresent
args:
- --config=/etc/otel/config.yaml
- --config=/etc/otel/test-config.yaml
resources:
limits:
cpu: 2000m
Expand Down

0 comments on commit 7134ef4

Please sign in to comment.