Skip to content
This repository was archived by the owner on Mar 28, 2025. It is now read-only.

Commit 0ecfeeb

Browse files
authored
Bump Telegraf image to 1.22 (#96)
* Bump Telegraf image to 1.22 Co-authored-by: Pawel Zak <Pawel Zak>
1 parent d0d2b4b commit 0ecfeeb

File tree

3 files changed

+22
-22
lines changed

3 files changed

+22
-22
lines changed

handler_test.go

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@ func Test_podInjector_Handle(t *testing.T) {
216216
Patches: []string{
217217
`{"op":"add","path":"/metadata/creationTimestamp"}`,
218218
`{"op":"add","path":"/spec/containers/0/resources","value":{}}`,
219-
`{"op":"add","path":"/spec/containers/1","value":{"command":["telegraf","--config","/etc/telegraf/telegraf.conf"],"env":[{"name":"NODENAME","valueFrom":{"fieldRef":{"fieldPath":"spec.nodeName"}}}],"image":"docker.io/library/telegraf:1.19","name":"telegraf","resources":{"limits":{"cpu":"200m","memory":"200Mi"},"requests":{"cpu":"10m","memory":"10Mi"}},"volumeMounts":[{"mountPath":"/etc/telegraf","name":"telegraf-config"}]}}`,
219+
`{"op":"add","path":"/spec/containers/1","value":{"command":["telegraf","--config","/etc/telegraf/telegraf.conf"],"env":[{"name":"NODENAME","valueFrom":{"fieldRef":{"fieldPath":"spec.nodeName"}}}],"image":"docker.io/library/telegraf:1.22","name":"telegraf","resources":{"limits":{"cpu":"200m","memory":"200Mi"},"requests":{"cpu":"10m","memory":"10Mi"}},"volumeMounts":[{"mountPath":"/etc/telegraf","name":"telegraf-config"}]}}`,
220220
`{"op":"add","path":"/spec/volumes","value":[{"name":"telegraf-config","secret":{"secretName":"telegraf-config-simple"}}]}`,
221221
`{"op":"add","path":"/status","value":{}}`,
222222
},
@@ -377,7 +377,7 @@ func Test_podInjector_Handle(t *testing.T) {
377377
Patches: []string{
378378
`{"op":"add","path":"/metadata/creationTimestamp"}`,
379379
`{"op":"add","path":"/spec/containers/0/resources","value":{}}`,
380-
`{"op":"add","path":"/spec/containers/1","value":{"command":["telegraf","--config","/etc/telegraf/telegraf.conf"],"env":[{"name":"NODENAME","valueFrom":{"fieldRef":{"fieldPath":"spec.nodeName"}}}],"image":"docker.io/library/telegraf:1.19","name":"telegraf","resources":{"limits":{"cpu":"200m","memory":"200Mi"},"requests":{"cpu":"10m","memory":"10Mi"}},"volumeMounts":[{"mountPath":"/etc/telegraf","name":"telegraf-config"}]}}`,
380+
`{"op":"add","path":"/spec/containers/1","value":{"command":["telegraf","--config","/etc/telegraf/telegraf.conf"],"env":[{"name":"NODENAME","valueFrom":{"fieldRef":{"fieldPath":"spec.nodeName"}}}],"image":"docker.io/library/telegraf:1.22","name":"telegraf","resources":{"limits":{"cpu":"200m","memory":"200Mi"},"requests":{"cpu":"10m","memory":"10Mi"}},"volumeMounts":[{"mountPath":"/etc/telegraf","name":"telegraf-config"}]}}`,
381381
`{"op":"add","path":"/spec/volumes","value":[{"name":"telegraf-config","secret":{"secretName":"telegraf-config-simple"}}]}`,
382382
`{"op":"add","path":"/status","value":{}}`,
383383
},
@@ -492,7 +492,7 @@ func Test_podInjector_Handle(t *testing.T) {
492492
Patches: []string{
493493
`{"op":"add","path":"/metadata/creationTimestamp"}`,
494494
`{"op":"add","path":"/spec/containers/0/resources","value":{}}`,
495-
`{"op":"add","path":"/spec/containers/1","value":{"command":["telegraf","--config","/etc/telegraf/telegraf.conf"],"env":[{"name":"NODENAME","valueFrom":{"fieldRef":{"fieldPath":"spec.nodeName"}}}],"image":"docker.io/library/telegraf:1.19","name":"telegraf","resources":{"limits":{"cpu":"200m","memory":"200Mi"},"requests":{"cpu":"10m","memory":"10Mi"}},"volumeMounts":[{"mountPath":"/etc/telegraf","name":"telegraf-config"}]}}`,
495+
`{"op":"add","path":"/spec/containers/1","value":{"command":["telegraf","--config","/etc/telegraf/telegraf.conf"],"env":[{"name":"NODENAME","valueFrom":{"fieldRef":{"fieldPath":"spec.nodeName"}}}],"image":"docker.io/library/telegraf:1.22","name":"telegraf","resources":{"limits":{"cpu":"200m","memory":"200Mi"},"requests":{"cpu":"10m","memory":"10Mi"}},"volumeMounts":[{"mountPath":"/etc/telegraf","name":"telegraf-config"}]}}`,
496496
`{"op":"add","path":"/spec/volumes","value":[{"name":"telegraf-config","secret":{"secretName":"telegraf-config-simple"}}]}`,
497497
`{"op":"add","path":"/status","value":{}}`,
498498
},
@@ -543,7 +543,7 @@ func Test_podInjector_Handle(t *testing.T) {
543543
Patches: []string{
544544
`{"op":"add","path":"/metadata/creationTimestamp"}`,
545545
`{"op":"add","path":"/spec/containers/0/resources","value":{}}`,
546-
`{"op":"add","path":"/spec/containers/1","value":{"command":["telegraf","--config","/etc/telegraf/telegraf.conf"],"env":[{"name":"NODENAME","valueFrom":{"fieldRef":{"fieldPath":"spec.nodeName"}}}],"image":"docker.io/library/telegraf:1.19","name":"telegraf","resources":{"limits":{"cpu":"750m","memory":"200Mi"},"requests":{"cpu":"10m","memory":"10Mi"}},"volumeMounts":[{"mountPath":"/etc/telegraf","name":"telegraf-config"}]}}`,
546+
`{"op":"add","path":"/spec/containers/1","value":{"command":["telegraf","--config","/etc/telegraf/telegraf.conf"],"env":[{"name":"NODENAME","valueFrom":{"fieldRef":{"fieldPath":"spec.nodeName"}}}],"image":"docker.io/library/telegraf:1.22","name":"telegraf","resources":{"limits":{"cpu":"750m","memory":"200Mi"},"requests":{"cpu":"10m","memory":"10Mi"}},"volumeMounts":[{"mountPath":"/etc/telegraf","name":"telegraf-config"}]}}`,
547547
`{"op":"add","path":"/spec/volumes","value":[{"name":"telegraf-config","secret":{"secretName":"telegraf-config-simple"}}]}`,
548548
`{"op":"add","path":"/status","value":{}}`,
549549
},
@@ -636,7 +636,7 @@ func Test_podInjector_Handle(t *testing.T) {
636636
Patches: []string{
637637
`{"op":"add","path":"/metadata/creationTimestamp"}`,
638638
`{"op":"add","path":"/spec/containers/0/resources","value":{}}`,
639-
`{"op":"add","path":"/spec/containers/1","value":{"command":["telegraf","--config","/etc/telegraf/telegraf.conf"],"env":[{"name":"NODENAME","valueFrom":{"fieldRef":{"fieldPath":"spec.nodeName"}}}],"image":"docker.io/library/telegraf:1.19","name":"telegraf-istio","resources":{"limits":{"cpu":"200m","memory":"200Mi"},"requests":{"cpu":"10m","memory":"10Mi"}},"volumeMounts":[{"mountPath":"/etc/telegraf","name":"telegraf-istio-config"}]}}`,
639+
`{"op":"add","path":"/spec/containers/1","value":{"command":["telegraf","--config","/etc/telegraf/telegraf.conf"],"env":[{"name":"NODENAME","valueFrom":{"fieldRef":{"fieldPath":"spec.nodeName"}}}],"image":"docker.io/library/telegraf:1.22","name":"telegraf-istio","resources":{"limits":{"cpu":"200m","memory":"200Mi"},"requests":{"cpu":"10m","memory":"10Mi"}},"volumeMounts":[{"mountPath":"/etc/telegraf","name":"telegraf-istio-config"}]}}`,
640640
`{"op":"add","path":"/spec/volumes","value":[{"name":"telegraf-istio-config","secret":{"secretName":"telegraf-istio-config-simple"}}]}`,
641641
`{"op":"add","path":"/status","value":{}}`,
642642
},
@@ -693,8 +693,8 @@ func Test_podInjector_Handle(t *testing.T) {
693693
Patches: []string{
694694
`{"op":"add","path":"/metadata/creationTimestamp"}`,
695695
`{"op":"add","path":"/spec/containers/0/resources","value":{}}`,
696-
`{"op":"add","path":"/spec/containers/1","value":{"command":["telegraf","--config","/etc/telegraf/telegraf.conf"],"env":[{"name":"NODENAME","valueFrom":{"fieldRef":{"fieldPath":"spec.nodeName"}}}],"image":"docker.io/library/telegraf:1.19","name":"telegraf","resources":{"limits":{"cpu":"200m","memory":"200Mi"},"requests":{"cpu":"10m","memory":"10Mi"}},"volumeMounts":[{"mountPath":"/etc/telegraf","name":"telegraf-config"}]}}`,
697-
`{"op":"add","path":"/spec/containers/2","value":{"command":["telegraf","--config","/etc/telegraf/telegraf.conf"],"env":[{"name":"NODENAME","valueFrom":{"fieldRef":{"fieldPath":"spec.nodeName"}}}],"image":"docker.io/library/telegraf:1.19","name":"telegraf-istio","resources":{"limits":{"cpu":"200m","memory":"200Mi"},"requests":{"cpu":"10m","memory":"10Mi"}},"volumeMounts":[{"mountPath":"/etc/telegraf","name":"telegraf-istio-config"}]}}`,
696+
`{"op":"add","path":"/spec/containers/1","value":{"command":["telegraf","--config","/etc/telegraf/telegraf.conf"],"env":[{"name":"NODENAME","valueFrom":{"fieldRef":{"fieldPath":"spec.nodeName"}}}],"image":"docker.io/library/telegraf:1.22","name":"telegraf","resources":{"limits":{"cpu":"200m","memory":"200Mi"},"requests":{"cpu":"10m","memory":"10Mi"}},"volumeMounts":[{"mountPath":"/etc/telegraf","name":"telegraf-config"}]}}`,
697+
`{"op":"add","path":"/spec/containers/2","value":{"command":["telegraf","--config","/etc/telegraf/telegraf.conf"],"env":[{"name":"NODENAME","valueFrom":{"fieldRef":{"fieldPath":"spec.nodeName"}}}],"image":"docker.io/library/telegraf:1.22","name":"telegraf-istio","resources":{"limits":{"cpu":"200m","memory":"200Mi"},"requests":{"cpu":"10m","memory":"10Mi"}},"volumeMounts":[{"mountPath":"/etc/telegraf","name":"telegraf-istio-config"}]}}`,
698698
`{"op":"add","path":"/spec/volumes","value":[{"name":"telegraf-config","secret":{"secretName":"telegraf-config-simple"}},{"name":"telegraf-istio-config","secret":{"secretName":"telegraf-istio-config-simple"}}]}`,
699699
`{"op":"add","path":"/status","value":{}}`,
700700
},

main.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ var (
3838
)
3939

4040
const (
41-
defaultTelegrafImage = "docker.io/library/telegraf:1.19"
41+
defaultTelegrafImage = "docker.io/library/telegraf:1.22"
4242
defaultRequestsCPU = "10m"
4343
defaultRequestsMemory = "10Mi"
4444
defaultLimitsCPU = "200m"

sidecar_test.go

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -450,7 +450,7 @@ spec:
450450
valueFrom:
451451
fieldRef:
452452
fieldPath: spec.nodeName
453-
image: docker.io/library/telegraf:1.19
453+
image: docker.io/library/telegraf:1.22
454454
name: telegraf
455455
resources:
456456
limits:
@@ -576,7 +576,7 @@ spec:
576576
valueFrom:
577577
fieldRef:
578578
fieldPath: spec.nodeName
579-
image: docker.io/library/telegraf:1.19
579+
image: docker.io/library/telegraf:1.22
580580
name: telegraf
581581
resources:
582582
limits:
@@ -623,7 +623,7 @@ spec:
623623
valueFrom:
624624
fieldRef:
625625
fieldPath: spec.nodeName
626-
image: docker.io/library/telegraf:1.19
626+
image: docker.io/library/telegraf:1.22
627627
name: telegraf
628628
resources:
629629
limits:
@@ -670,7 +670,7 @@ spec:
670670
valueFrom:
671671
fieldRef:
672672
fieldPath: spec.nodeName
673-
image: docker.io/library/telegraf:1.19
673+
image: docker.io/library/telegraf:1.22
674674
name: telegraf
675675
resources:
676676
limits:
@@ -768,7 +768,7 @@ spec:
768768
valueFrom:
769769
fieldRef:
770770
fieldPath: spec.nodeName
771-
image: docker.io/library/telegraf:1.19
771+
image: docker.io/library/telegraf:1.22
772772
name: telegraf-istio
773773
resources:
774774
limits:
@@ -898,7 +898,7 @@ spec:
898898
valueFrom:
899899
fieldRef:
900900
fieldPath: spec.nodeName
901-
image: docker.io/library/telegraf:1.19
901+
image: docker.io/library/telegraf:1.22
902902
name: telegraf
903903
resources:
904904
limits:
@@ -919,7 +919,7 @@ spec:
919919
valueFrom:
920920
fieldRef:
921921
fieldPath: spec.nodeName
922-
image: docker.io/library/telegraf:1.19
922+
image: docker.io/library/telegraf:1.22
923923
name: telegraf-istio
924924
resources:
925925
limits:
@@ -972,7 +972,7 @@ spec:
972972
valueFrom:
973973
fieldRef:
974974
fieldPath: spec.nodeName
975-
image: docker.io/library/telegraf:1.19
975+
image: docker.io/library/telegraf:1.22
976976
name: telegraf
977977
resources:
978978
limits:
@@ -1021,7 +1021,7 @@ spec:
10211021
- secretRef:
10221022
name: mysecret
10231023
optional: true
1024-
image: docker.io/library/telegraf:1.19
1024+
image: docker.io/library/telegraf:1.22
10251025
name: telegraf
10261026
resources:
10271027
limits:
@@ -1070,7 +1070,7 @@ spec:
10701070
valueFrom:
10711071
fieldRef:
10721072
fieldPath: metadata.namespace
1073-
image: docker.io/library/telegraf:1.19
1073+
image: docker.io/library/telegraf:1.22
10741074
name: telegraf
10751075
resources:
10761076
limits:
@@ -1117,7 +1117,7 @@ spec:
11171117
fieldPath: spec.nodeName
11181118
- name: STACK_VERSION
11191119
value: "1.0"
1120-
image: docker.io/library/telegraf:1.19
1120+
image: docker.io/library/telegraf:1.22
11211121
name: telegraf
11221122
resources:
11231123
limits:
@@ -1167,7 +1167,7 @@ spec:
11671167
configMapKeyRef:
11681168
key: application.version
11691169
name: configmap-name
1170-
image: docker.io/library/telegraf:1.19
1170+
image: docker.io/library/telegraf:1.22
11711171
name: telegraf
11721172
resources:
11731173
limits:
@@ -1217,7 +1217,7 @@ spec:
12171217
secretKeyRef:
12181218
key: user.password
12191219
name: app-secret
1220-
image: docker.io/library/telegraf:1.19
1220+
image: docker.io/library/telegraf:1.22
12211221
name: telegraf
12221222
resources:
12231223
limits:
@@ -1270,7 +1270,7 @@ spec:
12701270
valueFrom:
12711271
fieldRef:
12721272
fieldPath: spec.nodeName
1273-
image: docker.io/library/telegraf:1.19
1273+
image: docker.io/library/telegraf:1.22
12741274
name: telegraf
12751275
resources: {}
12761276
volumeMounts:

0 commit comments

Comments
 (0)