Skip to content

Commit

Permalink
Merge pull request slok#416 from slok/slok/helm-scrape-interval
Browse files Browse the repository at this point in the history
  • Loading branch information
slok authored Oct 26, 2022
2 parents 4027a0a + 390c1af commit ac0182a
Show file tree
Hide file tree
Showing 7 changed files with 20 additions and 14 deletions.
2 changes: 1 addition & 1 deletion deploy/kubernetes/helm/sloth/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ description: Base chart for Sloth.
type: application
home: https://github.com/slok/sloth
kubeVersion: ">= 1.19.0-0"
version: 0.6.3
version: 0.6.4
3 changes: 3 additions & 0 deletions deploy/kubernetes/helm/sloth/templates/pod-monitor.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,7 @@ spec:
{{- include "sloth.selectorLabels" . | nindent 6 }}
podMetricsEndpoints:
- port: metrics
{{- with .Values.metrics.scrapeInterval }}
interval: {{.}}
{{- end }}
{{- end }}
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,4 @@ spec:
app.kubernetes.io/instance: test
podMetricsEndpoints:
- port: metrics
interval: 45s
3 changes: 2 additions & 1 deletion deploy/kubernetes/helm/sloth/tests/values_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,8 @@ func customValues() msi {
},

"metrics": msi{
"enabled": true,
"enabled": true,
"scrapeInterval": "45s",
"prometheusLabels": msi{
"kp1": "vp1",
"kp2": "vp2",
Expand Down
1 change: 1 addition & 0 deletions deploy/kubernetes/helm/sloth/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ commonPlugins:

metrics:
enabled: true
#scrapeInterval: 30s
prometheusLabels: {}

customSloConfig:
Expand Down
12 changes: 6 additions & 6 deletions deploy/kubernetes/raw/sloth-with-common-plugins.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ metadata:
name: sloth
namespace: monitoring
labels:
helm.sh/chart: sloth-0.6.3
helm.sh/chart: sloth-0.6.4
app.kubernetes.io/managed-by: Helm
app: sloth
app.kubernetes.io/name: sloth
Expand All @@ -18,7 +18,7 @@ kind: ClusterRole
metadata:
name: sloth
labels:
helm.sh/chart: sloth-0.6.3
helm.sh/chart: sloth-0.6.4
app.kubernetes.io/managed-by: Helm
app: sloth
app.kubernetes.io/name: sloth
Expand All @@ -38,7 +38,7 @@ kind: ClusterRoleBinding
metadata:
name: sloth
labels:
helm.sh/chart: sloth-0.6.3
helm.sh/chart: sloth-0.6.4
app.kubernetes.io/managed-by: Helm
app: sloth
app.kubernetes.io/name: sloth
Expand All @@ -59,7 +59,7 @@ metadata:
name: sloth
namespace: monitoring
labels:
helm.sh/chart: sloth-0.6.3
helm.sh/chart: sloth-0.6.4
app.kubernetes.io/managed-by: Helm
app: sloth
app.kubernetes.io/name: sloth
Expand All @@ -74,7 +74,7 @@ spec:
template:
metadata:
labels:
helm.sh/chart: sloth-0.6.3
helm.sh/chart: sloth-0.6.4
app.kubernetes.io/managed-by: Helm
app: sloth
app.kubernetes.io/name: sloth
Expand Down Expand Up @@ -132,7 +132,7 @@ metadata:
name: sloth
namespace: monitoring
labels:
helm.sh/chart: sloth-0.6.3
helm.sh/chart: sloth-0.6.4
app.kubernetes.io/managed-by: Helm
app: sloth
app.kubernetes.io/name: sloth
Expand Down
12 changes: 6 additions & 6 deletions deploy/kubernetes/raw/sloth.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ metadata:
name: sloth
namespace: monitoring
labels:
helm.sh/chart: sloth-0.6.3
helm.sh/chart: sloth-0.6.4
app.kubernetes.io/managed-by: Helm
app: sloth
app.kubernetes.io/name: sloth
Expand All @@ -18,7 +18,7 @@ kind: ClusterRole
metadata:
name: sloth
labels:
helm.sh/chart: sloth-0.6.3
helm.sh/chart: sloth-0.6.4
app.kubernetes.io/managed-by: Helm
app: sloth
app.kubernetes.io/name: sloth
Expand All @@ -38,7 +38,7 @@ kind: ClusterRoleBinding
metadata:
name: sloth
labels:
helm.sh/chart: sloth-0.6.3
helm.sh/chart: sloth-0.6.4
app.kubernetes.io/managed-by: Helm
app: sloth
app.kubernetes.io/name: sloth
Expand All @@ -59,7 +59,7 @@ metadata:
name: sloth
namespace: monitoring
labels:
helm.sh/chart: sloth-0.6.3
helm.sh/chart: sloth-0.6.4
app.kubernetes.io/managed-by: Helm
app: sloth
app.kubernetes.io/name: sloth
Expand All @@ -74,7 +74,7 @@ spec:
template:
metadata:
labels:
helm.sh/chart: sloth-0.6.3
helm.sh/chart: sloth-0.6.4
app.kubernetes.io/managed-by: Helm
app: sloth
app.kubernetes.io/name: sloth
Expand Down Expand Up @@ -107,7 +107,7 @@ metadata:
name: sloth
namespace: monitoring
labels:
helm.sh/chart: sloth-0.6.3
helm.sh/chart: sloth-0.6.4
app.kubernetes.io/managed-by: Helm
app: sloth
app.kubernetes.io/name: sloth
Expand Down

0 comments on commit ac0182a

Please sign in to comment.