sidekiq-prometheus-exporter 0.2.0 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. checksums.yaml +4 -4
  2. data/.rubocop.yml +6 -3
  3. data/Appraisals +6 -4
  4. data/Gemfile +13 -0
  5. data/README.md +11 -3
  6. data/Rakefile +20 -4
  7. data/lib/sidekiq/prometheus/exporter/standard.rb +73 -21
  8. data/lib/sidekiq/prometheus/exporter/templates/standard.erb +37 -8
  9. data/lib/sidekiq/prometheus/exporter/version.rb +1 -1
  10. data/lib/sidekiq/prometheus/exporter.rb +5 -4
  11. data/sidekiq-prometheus-exporter.gemspec +2 -15
  12. metadata +4 -211
  13. data/.github/FUNDING.yml +0 -12
  14. data/.github/workflows/ci.yaml +0 -70
  15. data/docker/Dockerfile +0 -24
  16. data/docker/README.md +0 -61
  17. data/docker/config.ru +0 -41
  18. data/examples/docker-compose.yml +0 -49
  19. data/examples/metrics/Dockerfile +0 -7
  20. data/examples/metrics/config.ru +0 -10
  21. data/examples/prometheus/prometheus.yml +0 -8
  22. data/examples/screenshot.png +0 -0
  23. data/examples/sidekiq/Dockerfile +0 -5
  24. data/examples/sidekiq/sidekiq.rb +0 -41
  25. data/examples/sidekiq/sidekiq.yml +0 -5
  26. data/examples/sidekiq-dashboard.grafana-6.json +0 -837
  27. data/examples/sidekiq-dashboard.grafana-7.json +0 -845
  28. data/gemfiles/sidekiq_4.1.0.Gemfile +0 -9
  29. data/gemfiles/sidekiq_4.1.0.Gemfile.lock +0 -117
  30. data/gemfiles/sidekiq_4.x.Gemfile +0 -8
  31. data/gemfiles/sidekiq_4.x.Gemfile.lock +0 -105
  32. data/gemfiles/sidekiq_5.x.Gemfile +0 -8
  33. data/gemfiles/sidekiq_5.x.Gemfile.lock +0 -104
  34. data/gemfiles/sidekiq_6.x.Gemfile +0 -8
  35. data/gemfiles/sidekiq_6.x.Gemfile.lock +0 -101
  36. data/gemfiles/sidekiq_7.x.Gemfile +0 -8
  37. data/gemfiles/sidekiq_7.x.Gemfile.lock +0 -109
  38. data/gemfiles/sidekiq_latest.Gemfile +0 -9
  39. data/gemfiles/sidekiq_latest.Gemfile.lock +0 -121
  40. data/helm/sidekiq-prometheus-exporter/.helmignore +0 -22
  41. data/helm/sidekiq-prometheus-exporter/Chart.yaml +0 -6
  42. data/helm/sidekiq-prometheus-exporter/README.md +0 -89
  43. data/helm/sidekiq-prometheus-exporter/templates/NOTES.txt +0 -15
  44. data/helm/sidekiq-prometheus-exporter/templates/_helpers.tpl +0 -109
  45. data/helm/sidekiq-prometheus-exporter/templates/clusterrole.yaml +0 -20
  46. data/helm/sidekiq-prometheus-exporter/templates/clusterrolebinding.yaml +0 -17
  47. data/helm/sidekiq-prometheus-exporter/templates/deployment.yaml +0 -65
  48. data/helm/sidekiq-prometheus-exporter/templates/service.yaml +0 -17
  49. data/helm/sidekiq-prometheus-exporter/templates/serviceaccount.yaml +0 -9
  50. data/helm/sidekiq-prometheus-exporter/templates/servicemonitor.yaml +0 -26
  51. data/helm/sidekiq-prometheus-exporter/values.yaml +0 -139
@@ -1,121 +0,0 @@
1
- GIT
2
- remote: https://github.com/mperham/sidekiq
3
- revision: 1db35cc3d722c3e9d53848d699f9aa1ba097443c
4
- specs:
5
- sidekiq (7.0.1)
6
- concurrent-ruby (< 2)
7
- connection_pool (>= 2.3.0)
8
- rack (>= 2.2.4)
9
- redis-client (>= 0.9.0)
10
-
11
- GIT
12
- remote: https://github.com/rack/rack
13
- revision: 253fc5b29c240276d3cf573bdf795e6a6126b16f
14
- specs:
15
- rack (2.3.0)
16
- rack-session
17
-
18
- GIT
19
- remote: https://github.com/redis/redis-rb
20
- revision: 5fb64bdecacac0bc5738f194ab82cd1001071879
21
- specs:
22
- redis (4.6.0)
23
-
24
- PATH
25
- remote: ..
26
- specs:
27
- sidekiq-prometheus-exporter (0.1.17)
28
- rack (>= 1.6.0)
29
- sidekiq (>= 3.3.1)
30
-
31
- GEM
32
- remote: https://rubygems.org/
33
- specs:
34
- appraisal (2.4.1)
35
- bundler
36
- rake
37
- thor (>= 0.14.0)
38
- ast (2.4.2)
39
- byebug (11.1.3)
40
- coderay (1.1.3)
41
- concurrent-ruby (1.1.10)
42
- connection_pool (2.3.0)
43
- diff-lcs (1.5.0)
44
- method_source (1.0.0)
45
- parallel (1.21.0)
46
- parser (3.1.1.0)
47
- ast (~> 2.4.1)
48
- pry (0.14.2)
49
- coderay (~> 1.1)
50
- method_source (~> 1.0)
51
- pry-byebug (3.10.1)
52
- byebug (~> 11.0)
53
- pry (>= 0.13, < 0.15)
54
- rack-session (0.1.0)
55
- rack-test (1.1.0)
56
- rack (>= 1.0, < 3)
57
- rainbow (3.1.1)
58
- rake (13.0.6)
59
- redis-client (0.11.2)
60
- connection_pool
61
- regexp_parser (2.2.1)
62
- rexml (3.2.5)
63
- rspec (3.11.0)
64
- rspec-core (~> 3.11.0)
65
- rspec-expectations (~> 3.11.0)
66
- rspec-mocks (~> 3.11.0)
67
- rspec-core (3.11.0)
68
- rspec-support (~> 3.11.0)
69
- rspec-expectations (3.11.0)
70
- diff-lcs (>= 1.2.0, < 2.0)
71
- rspec-support (~> 3.11.0)
72
- rspec-mocks (3.11.0)
73
- diff-lcs (>= 1.2.0, < 2.0)
74
- rspec-support (~> 3.11.0)
75
- rspec-support (3.11.0)
76
- rubocop (1.26.0)
77
- parallel (~> 1.10)
78
- parser (>= 3.1.0.0)
79
- rainbow (>= 2.2.2, < 4.0)
80
- regexp_parser (>= 1.8, < 3.0)
81
- rexml
82
- rubocop-ast (>= 1.16.0, < 2.0)
83
- ruby-progressbar (~> 1.7)
84
- unicode-display_width (>= 1.4.0, < 3.0)
85
- rubocop-ast (1.16.0)
86
- parser (>= 3.1.1.0)
87
- rubocop-performance (1.13.3)
88
- rubocop (>= 1.7.0, < 2.0)
89
- rubocop-ast (>= 0.4.0)
90
- rubocop-rake (0.6.0)
91
- rubocop (~> 1.0)
92
- rubocop-rspec (2.9.0)
93
- rubocop (~> 1.19)
94
- ruby-progressbar (1.11.0)
95
- thor (1.2.1)
96
- timecop (0.9.5)
97
- unicode-display_width (2.1.0)
98
-
99
- PLATFORMS
100
- ruby
101
-
102
- DEPENDENCIES
103
- appraisal (~> 2.2)
104
- bundler (~> 2.1)
105
- pry (~> 0.14)
106
- pry-byebug (~> 3.6)
107
- rack (>= 2)!
108
- rack-test (~> 1.1)
109
- rake (~> 13.0)
110
- redis (>= 4)!
111
- rspec (~> 3.0)
112
- rubocop (~> 1.22)
113
- rubocop-performance (~> 1.12)
114
- rubocop-rake (~> 0.6)
115
- rubocop-rspec (~> 2.6)
116
- sidekiq (>= 6)!
117
- sidekiq-prometheus-exporter!
118
- timecop (~> 0.9)
119
-
120
- BUNDLED WITH
121
- 2.3.26
@@ -1,22 +0,0 @@
1
- # Patterns to ignore when building packages.
2
- # This supports shell glob matching, relative path matching, and
3
- # negation (prefixed with !). Only one pattern per line.
4
- .DS_Store
5
- # Common VCS dirs
6
- .git/
7
- .gitignore
8
- .bzr/
9
- .bzrignore
10
- .hg/
11
- .hgignore
12
- .svn/
13
- # Common backup files
14
- *.swp
15
- *.bak
16
- *.tmp
17
- *~
18
- # Various IDEs
19
- .project
20
- .idea/
21
- *.tmproj
22
- .vscode/
@@ -1,6 +0,0 @@
1
- ---
2
- apiVersion: v1
3
- appVersion: 0.1.17-2
4
- description: A Helm chart to deploy sidekiq-prometheus-exporter in Kubernetes
5
- name: sidekiq-prometheus-exporter
6
- version: 0.1.18
@@ -1,89 +0,0 @@
1
- # Official Helm chart
2
-
3
- This is an official Helm chart for [sidekiq-prometheus-exporter](https://github.com/Strech/sidekiq-prometheus-exporter)
4
- gem. It uses Docker image published on the [Docker hub](https://hub.docker.com/r/strech/sidekiq-prometheus-exporter).
5
-
6
- ## Installation
7
-
8
- First of all add the chart repository
9
-
10
- ```console
11
- $ helm repo add strech https://strech.github.io/sidekiq-prometheus-exporter
12
- "strech" has been added to your repositories
13
-
14
- $ helm repo list
15
- NAME URL
16
- strech https://strech.github.io/sidekiq-prometheus-exporter
17
- ```
18
-
19
- Then you can install the chart, let's say with the release name `sidekiq-metrics`
20
-
21
- **Helm v2**
22
-
23
- ```console
24
- $ helm install strech/sidekiq-prometheus-exporter --name sidekiq-metrics
25
- ```
26
-
27
- **Helm v3**
28
-
29
- ```console
30
- $ helm install sidekiq-metrics strech/sidekiq-prometheus-exporter
31
- ```
32
-
33
- ## Configuration
34
-
35
- You can try out that configuration by using `--dry-run` and `--values` on
36
- install (examples using **Helm v3**)
37
-
38
- ```console
39
- $ helm install sidekiq-metrics strech/sidekiq-prometheus-exporter --values myvalues.yaml --dry-run
40
- ```
41
-
42
- or you can try out just one value via `--set`
43
-
44
- ```console
45
- $ helm install sidekiq-metrics strech/sidekiq-prometheus-exporter --set serviceAccount.create=false --dry-run
46
- ```
47
-
48
- | Parameter | Description | Default |
49
- | ------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------ |
50
- | `nameOverride` | Override the resource name prefix | `nil` |
51
- | `fullnameOverride` | Override the full resource names | `nil` |
52
- | `image.registry` | Image registry | `docker.io` |
53
- | `image.repository` | Image repository | `strech/sidekiq-prometheus-exporter` |
54
- | `image.tag` | Image tag | `0.1.17-2` |
55
- | `image.pullPolicy` | Image pull policy | `IfNotPresent` |
56
- | `image.pullSecrets` | Image pull secrets | `nil` |
57
- | `containerPort` | Port for the exporter to bind on | `9292` |
58
- | `resources` | CPU/Memory resource requests/limits | `nil` |
59
- | `nodeSelector` | Node labels for pod assignment | `nil` |
60
- | `tolerations` | Toleration labels for pod assignment | `nil` |
61
- | `affinity` | Affinity settings for pod assignment | `nil` |
62
- | `securityContext` | Security Context for the pod | `nil` |
63
- | `podLabels` | Pod labels additional to the default | `nil` |
64
- | `podAnnotations` | Pod annotations | `nil` |
65
- | `livenessProbe` | LivenessProbe settings for tcpSocket mapping to containerPort | (See `values.yaml`) |
66
- | `readinessProbe` | ReadinessProbe settings for tcpSocket mapping to containerPort | (See `values.yaml`) |
67
- | `service.type` | Kubernetes service type | `ClusterIP` |
68
- | `service.port` | Kubernetes port where service is exposed | `80` |
69
- | `env` | An environment variables for metrics container (exclusive with `envFrom`) | `nil` |
70
- | `envFrom.type` | Type of resource configMapRef/secretRef to source environment variables from | `nil` |
71
- | `envFrom.name` | Name of Secret/ConfigMap to source environment variables from | `nil` |
72
- | `serviceMonitor.enabled` | Whether serviceMonitor resource should be deployed | `false` |
73
- | `serviceMonitor.path` | The endpoint of the service to be scraped | `/metrics` |
74
- | `serviceMonitor.interval` | Duration between 2 consecutive scrapes | `1m` |
75
- | `serviceMonitor.scrapeTimeout` | Timeout for each scrape request | `nil` |
76
- | `serviceMonitor.labels` | Labels to add to the service monitor object | `nil` |
77
- | `serviceAccount.create` | Specifies whether a service account should be created | `true` |
78
- | `serviceAccount.name` | Name of the service account (if not set will be generated from chart full name) | `nil` |
79
- | `rbac.create` | If true, create & use RBAC resources (:anger: works with `envFrom` and `serviceAccount` enabled) | `false` |
80
-
81
- ## How to uninstall?
82
-
83
- If you already have release `sidekiq-metics` running and want to remove it
84
-
85
- ```console
86
- $ helm delete --purge sidekiq-metics
87
- ```
88
-
89
- :bulb: The command above removes all the Kubernetes components associated with the chart and deletes the release.
@@ -1,15 +0,0 @@
1
- Try out an exporter metrics:
2
- {{- if contains "NodePort" .Values.service.type }}
3
- export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "sidekiq-prometheus-exporter.fullname" . }})
4
- export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
5
- echo "Run the following command: curl http://$NODE_IP:$NODE_PORT/metrics"
6
- {{- else if contains "LoadBalancer" .Values.service.type }}
7
- NOTE: It may take a few minutes for the LoadBalancer IP to be available.
8
- You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "sidekiq-prometheus-exporter.fullname" . }}'
9
- export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "sidekiq-prometheus-exporter.fullname" . }} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')
10
- echo "Run the following command: curl http://$SERVICE_IP:{{ .Values.service.port }}/metrics"
11
- {{- else if contains "ClusterIP" .Values.service.type }}
12
- export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "sidekiq-prometheus-exporter.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
13
- kubectl port-forward $POD_NAME 9292:{{ .Values.containerPort }}
14
- echo "Run the following command: curl http://127.0.0.1:9292/metrics"
15
- {{- end }}
@@ -1,109 +0,0 @@
1
- {{/* vim: set filetype=mustache: */}}
2
- {{/*
3
- Expand the name of the chart.
4
- */}}
5
- {{- define "sidekiq-prometheus-exporter.name" -}}
6
- {{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
7
- {{- end -}}
8
-
9
- {{/*
10
- Expand the name of the docker image.
11
- */}}
12
- {{- define "sidekiq-prometheus-exporter.image" -}}
13
- {{- $registryName := .Values.image.registry -}}
14
- {{- $repositoryName := .Values.image.repository -}}
15
- {{- $tag := .Values.image.tag | toString -}}
16
- {{- printf "%s/%s:%s" $registryName $repositoryName $tag -}}
17
- {{- end -}}
18
-
19
- {{/*
20
- Create a default fully qualified app name.
21
- We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
22
- If release name contains chart name it will be used as a full name.
23
- */}}
24
- {{- define "sidekiq-prometheus-exporter.fullname" -}}
25
- {{- if .Values.fullnameOverride -}}
26
- {{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}}
27
- {{- else -}}
28
- {{- $name := default .Chart.Name .Values.nameOverride -}}
29
- {{- if contains $name .Release.Name -}}
30
- {{- .Release.Name | trunc 63 | trimSuffix "-" -}}
31
- {{- else -}}
32
- {{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
33
- {{- end -}}
34
- {{- end -}}
35
- {{- end -}}
36
-
37
- {{/*
38
- Create chart name and version as used by the chart label.
39
- */}}
40
- {{- define "sidekiq-prometheus-exporter.chart" -}}
41
- {{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
42
- {{- end -}}
43
-
44
- {{/*
45
- Create the name of the service account to use.
46
- */}}
47
- {{- define "sidekiq-prometheus-exporter.serviceAccountName" -}}
48
- {{- if .Values.serviceAccount.create -}}
49
- {{ default (include "sidekiq-prometheus-exporter.fullname" .) .Values.serviceAccount.name }}
50
- {{- else -}}
51
- {{ default "default" .Values.serviceAccount.name }}
52
- {{- end -}}
53
- {{- end -}}
54
-
55
- {{/*
56
- Create pod service account name.
57
- */}}
58
- {{- define "sidekiq-prometheus-exporter.podServiceAccountName" -}}
59
- {{- if and .Values.serviceAccount .Values.serviceAccount.create -}}
60
- serviceAccountName: {{ include "sidekiq-prometheus-exporter.serviceAccountName" . }}
61
- {{- end -}}
62
- {{- end -}}
63
-
64
- {{/*
65
- Create pod image pull secrets.
66
- */}}
67
- {{- define "sidekiq-prometheus-exporter.podImagePullSecrets" -}}
68
- {{- if .Values.image.pullSecrets -}}
69
- imagePullSecrets:
70
- {{- range .Values.image.pullSecrets }}
71
- - name: {{ . }}
72
- {{- end }}
73
- {{- end -}}
74
- {{- end -}}
75
-
76
- {{/*
77
- Create container environment variables.
78
- */}}
79
- {{- define "sidekiq-prometheus-exporter.env" -}}
80
- {{- if .Values.envFrom -}}
81
- envFrom:
82
- {{ if eq (default "configMapRef" .Values.envFrom.type) "secretRef" -}}
83
- - secretRef:
84
- name: {{ .Values.envFrom.name }}
85
- {{- else -}}
86
- - configMapRef:
87
- name: {{ .Values.envFrom.name }}
88
- {{- end -}}
89
- {{- else if .Values.env -}}
90
- env:
91
- {{- range $name, $value := .Values.env }}
92
- - name: {{ $name }}
93
- value: {{ $value | quote }}
94
- {{- end }}
95
- {{- end -}}
96
- {{- end -}}
97
-
98
- {{/*
99
- Expand common labels.
100
- */}}
101
- {{- define "sidekiq-prometheus-exporter.labels" -}}
102
- app.kubernetes.io/name: {{ include "sidekiq-prometheus-exporter.name" . }}
103
- helm.sh/chart: {{ include "sidekiq-prometheus-exporter.chart" . }}
104
- app.kubernetes.io/instance: {{ .Release.Name }}
105
- {{- if .Chart.AppVersion }}
106
- app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
107
- {{- end }}
108
- app.kubernetes.io/managed-by: {{ .Release.Service }}
109
- {{- end -}}
@@ -1,20 +0,0 @@
1
- {{- if and .Values.rbac.create }}
2
- ---
3
- apiVersion: rbac.authorization.k8s.io/v1
4
- kind: ClusterRole
5
- metadata:
6
- name: {{ template "sidekiq-prometheus-exporter.fullname" . }}
7
- labels:
8
- {{- include "sidekiq-prometheus-exporter.labels" . | nindent 4 }}
9
- rules:
10
- - apiGroups: [""]
11
- resources:
12
- {{- if eq (default "configMapRef" .Values.envFrom.type) "secretRef" }}
13
- - "secrets"
14
- {{- else }}
15
- - "configmap"
16
- {{- end }}
17
- resourceNames:
18
- - {{ .Values.envFrom.name | quote }}
19
- verbs: ["get"]
20
- {{- end }}
@@ -1,17 +0,0 @@
1
- {{- if and .Values.rbac.create }}
2
- ---
3
- apiVersion: rbac.authorization.k8s.io/v1
4
- kind: ClusterRoleBinding
5
- metadata:
6
- name: {{ template "sidekiq-prometheus-exporter.fullname" . }}
7
- labels:
8
- {{- include "sidekiq-prometheus-exporter.labels" . | nindent 4 }}
9
- subjects:
10
- - kind: ServiceAccount
11
- name: {{ include "sidekiq-prometheus-exporter.serviceAccountName" . }}
12
- namespace: {{ .Release.Namespace }}
13
- roleRef:
14
- kind: ClusterRole
15
- name: {{ template "sidekiq-prometheus-exporter.fullname" . }}
16
- apiGroup: rbac.authorization.k8s.io
17
- {{- end }}
@@ -1,65 +0,0 @@
1
- ---
2
- apiVersion: apps/v1
3
- kind: Deployment
4
- metadata:
5
- name: {{ include "sidekiq-prometheus-exporter.fullname" . }}
6
- labels:
7
- {{- include "sidekiq-prometheus-exporter.labels" . | nindent 4 }}
8
- spec:
9
- replicas: 1
10
- selector:
11
- matchLabels:
12
- app.kubernetes.io/name: {{ include "sidekiq-prometheus-exporter.name" . }}
13
- app.kubernetes.io/instance: {{ .Release.Name }}
14
- template:
15
- metadata:
16
- labels:
17
- app.kubernetes.io/name: {{ include "sidekiq-prometheus-exporter.name" . }}
18
- app.kubernetes.io/instance: {{ .Release.Name }}
19
- {{- with .Values.podLabels }}
20
- {{- toYaml . | nindent 8 }}
21
- {{- end }}
22
- {{- with .Values.podAnnotations }}
23
- annotations:
24
- {{- toYaml . | nindent 8 }}
25
- {{- end }}
26
- spec:
27
- containers:
28
- - name: {{ .Chart.Name }}
29
- image: {{ include "sidekiq-prometheus-exporter.image" . }}
30
- imagePullPolicy: {{ .Values.image.pullPolicy }}
31
- ports:
32
- - name: metrics
33
- containerPort: {{ .Values.containerPort }}
34
- protocol: TCP
35
- {{- with .Values.resources }}
36
- resources:
37
- {{- toYaml . | nindent 12 }}
38
- {{- end }}
39
- livenessProbe:
40
- tcpSocket:
41
- port: metrics
42
- {{- toYaml .Values.livenessProbe | nindent 12 }}
43
- readinessProbe:
44
- tcpSocket:
45
- port: metrics
46
- {{- toYaml .Values.readinessProbe | nindent 12 }}
47
- {{- include "sidekiq-prometheus-exporter.env" . | nindent 10 }}
48
- {{- with .Values.nodeSelector }}
49
- nodeSelector:
50
- {{- toYaml . | nindent 8 }}
51
- {{- end }}
52
- {{- with .Values.affinity }}
53
- affinity:
54
- {{- toYaml . | nindent 8 }}
55
- {{- end }}
56
- {{- with .Values.tolerations }}
57
- tolerations:
58
- {{- toYaml . | nindent 8 }}
59
- {{- end }}
60
- {{- with .Values.securityContext }}
61
- securityContext:
62
- {{- toYaml . | nindent 8 }}
63
- {{- end }}
64
- {{- include "sidekiq-prometheus-exporter.podServiceAccountName" . | nindent 6 }}
65
- {{- include "sidekiq-prometheus-exporter.podImagePullSecrets" . | nindent 6 }}
@@ -1,17 +0,0 @@
1
- ---
2
- apiVersion: v1
3
- kind: Service
4
- metadata:
5
- name: {{ include "sidekiq-prometheus-exporter.fullname" . }}
6
- labels:
7
- {{- include "sidekiq-prometheus-exporter.labels" . | nindent 4 }}
8
- spec:
9
- type: {{ .Values.service.type }}
10
- ports:
11
- - port: {{ .Values.service.port }}
12
- targetPort: metrics
13
- protocol: TCP
14
- name: metrics
15
- selector:
16
- app.kubernetes.io/name: {{ include "sidekiq-prometheus-exporter.name" . }}
17
- app.kubernetes.io/instance: {{ .Release.Name }}
@@ -1,9 +0,0 @@
1
- {{- if .Values.serviceAccount.create }}
2
- ---
3
- apiVersion: v1
4
- kind: ServiceAccount
5
- metadata:
6
- name: {{ template "sidekiq-prometheus-exporter.fullname" . }}
7
- labels:
8
- {{- include "sidekiq-prometheus-exporter.labels" . | nindent 4 }}
9
- {{- end }}
@@ -1,26 +0,0 @@
1
- {{- if .Values.serviceMonitor.enabled }}
2
- ---
3
- apiVersion: monitoring.coreos.com/v1
4
- kind: ServiceMonitor
5
- metadata:
6
- name: {{ template "sidekiq-prometheus-exporter.fullname" . }}
7
- namespace: {{ .Release.Namespace | quote }}
8
- labels:
9
- {{- include "sidekiq-prometheus-exporter.labels" . | nindent 4 }}
10
- {{- with .Values.serviceMonitor.labels }}
11
- {{- toYaml . | nindent 4 }}
12
- {{- end }}
13
- spec:
14
- jobLabel: {{ template "sidekiq-prometheus-exporter.fullname" . }}
15
- selector:
16
- matchLabels:
17
- {{- include "sidekiq-prometheus-exporter.labels" . | nindent 6 }}
18
- namespaceSelector:
19
- matchNames:
20
- - {{ .Release.Namespace | quote }}
21
- endpoints:
22
- - port: metrics
23
- path: {{ .Values.serviceMonitor.path }}
24
- interval: {{ .Values.serviceMonitor.interval }}
25
- scrapeTimeout: {{ .Values.serviceMonitor.scrapeTimeout }}
26
- {{- end }}
@@ -1,139 +0,0 @@
1
- ---
2
- ## Default values for sidekiq-prometheus-exporter.
3
- ## This is a YAML-formatted file.
4
- ## Declare variables to be passed into your templates.
5
-
6
- ## Official docker image version
7
- ## ref: https://hub.docker.com/r/strech/sidekiq-prometheus-exporter/tags/
8
- ##
9
- image:
10
- registry: docker.io
11
- repository: strech/sidekiq-prometheus-exporter
12
- tag: 0.1.17-2
13
- ## Specify a imagePullPolicy
14
- ## Defaults to 'Always' if image tag is 'latest', else set to 'IfNotPresent'
15
- ## ref: http://kubernetes.io/docs/user-guide/images/#pre-pulling-images
16
- ##
17
- pullPolicy: IfNotPresent
18
- ## Optionally specify an array of imagePullSecrets.
19
- ## Secrets must be manually created in the namespace.
20
- ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/
21
- ##
22
- # pullSecrets:
23
- # - myRegistryKeySecretName
24
-
25
- ## String to partially override Values.fullname template (will maintain the release name)
26
- ##
27
- # nameOverride:
28
-
29
- ## String to fully override Values.fullname template
30
- ##
31
- # fullnameOverride:
32
-
33
- ## Metrics exporter resource requests and limits
34
- ## ref: http://kubernetes.io/docs/user-guide/compute-resources/
35
- ##
36
- # resources:
37
- # limits:
38
- # cpu: 100m
39
- # memory: 128Mi
40
- # requests:
41
- # cpu: 100m
42
- # memory: 128Mi
43
-
44
- ## Metrics exporter selectors and tolerations for pod assignment
45
- ## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#nodeselector
46
- ## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#taints-and-tolerations-beta-feature
47
- ##
48
- # nodeSelector:
49
- # tolerations:
50
-
51
- ## Metrics exporter pod/node affinity/anti-affinity
52
- ## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity
53
- ##
54
- # affinity:
55
-
56
- ## Metrics exporter liveness and readiness probes
57
- ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/
58
- ##
59
- livenessProbe:
60
- initialDelaySeconds: 5
61
- periodSeconds: 5
62
- timeoutSeconds: 5
63
- successThreshold: 1
64
- failureThreshold: 3
65
- readinessProbe:
66
- initialDelaySeconds: 5
67
- periodSeconds: 5
68
- timeoutSeconds: 5
69
- successThreshold: 1
70
- failureThreshold: 3
71
-
72
- ## Metrics exporter container port
73
- ##
74
- containerPort: 9292
75
-
76
- ## Metrics exporter container Environment Variables
77
- ## ref: https://github.com/Strech/sidekiq-prometheus-exporter/tree/master/docker#supported-envs
78
- ##
79
- # env:
80
- # REDIS_SSL: "false"
81
- # REDIS_HOST: "localhost"
82
- # REDIS_PORT: 6379
83
- # REDIS_URL: "..."
84
- # REDIS_PASSWORD: "..."
85
- # REDIS_DB_NUMBER: "0"
86
- # REDIS_NAMESPACE: "..."
87
- # REDIS_SENTINELS: "..."
88
- # REDIS_SENTINEL_ROLE: "..."
89
- # REDIS_DISABLE_CLIENT_ID: "false"
90
- # envFrom:
91
- # type: configMapRef
92
- # name: myConfigMapReference
93
-
94
- ## Metrics exporter Security Context
95
- ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context
96
- ##
97
- # securityContext:
98
- # runAsUser: 65534
99
-
100
- ## Metrics exporter pod Labels
101
- ##
102
- # podLabels:
103
-
104
- ## Metrics exporter pod Annotations
105
- ##
106
- # podAnnotations:
107
-
108
- ## Metrics exporter Service properties
109
- ##
110
- service:
111
- ## Metrics exporter Service type
112
- ##
113
- type: ClusterIP
114
- port: 80
115
-
116
- serviceAccount:
117
- ## Specifies whether a ServiceAccount should be created
118
- ##
119
- create: true
120
- ## The name of the ServiceAccount to use.
121
- ## If not set and create is true, a name is generated using the fullname template
122
- ##
123
- # name:
124
-
125
- rbac:
126
- ## Specifies whether RBAC resources should be created
127
- ##
128
- create: false
129
-
130
- ## Enable this if you're using https://github.com/coreos/prometheus-operator
131
- ##
132
- serviceMonitor:
133
- enabled: false
134
- path: "/metrics"
135
- interval: 1m
136
- scrapeTimeout: 10s
137
- ## Additional labels for the Service Monitor
138
- ##
139
- # labels: