mirror of
https://github.com/prometheus-operator/kube-prometheus.git
synced 2025-10-29 07:01:01 +01:00
jsonnet: fix thanos example
This commit is contained in:
parent
4f9d464087
commit
fe81e7de56
@ -1,9 +1,9 @@
|
|||||||
(import 'github.com/thanos-io/thanos/mixin/alerts/sidecar.libsonnet') +
|
(import 'github.com/thanos-io/thanos/mixin/alerts/sidecar.libsonnet') +
|
||||||
{
|
{
|
||||||
values+:: {
|
values+:: {
|
||||||
versions+:: { thanos: 'v0.14.0' },
|
|
||||||
imageRepos+:: { thanos: 'quay.io/thanos/thanos' },
|
|
||||||
thanos+:: {
|
thanos+:: {
|
||||||
|
version: '0.14.0',
|
||||||
|
image: 'quay.io/thanos/thanos:v0.14.0',
|
||||||
objectStorageConfig: {
|
objectStorageConfig: {
|
||||||
key: 'thanos.yaml', // How the file inside the secret is called
|
key: 'thanos.yaml', // How the file inside the secret is called
|
||||||
name: 'thanos-objectstorage', // This is the name of your Kubernetes secret with the config
|
name: 'thanos-objectstorage', // This is the name of your Kubernetes secret with the config
|
||||||
@ -26,9 +26,9 @@
|
|||||||
apiVersion: 'v1',
|
apiVersion: 'v1',
|
||||||
kind: 'Service',
|
kind: 'Service',
|
||||||
metadata: {
|
metadata: {
|
||||||
name: 'prometheus-' + p.name + '-thanos-sidecar',
|
name: 'prometheus-' + p.config.name + '-thanos-sidecar',
|
||||||
namespace: p.namespace,
|
namespace: p.config.namespace,
|
||||||
labels: { prometheus: p.name, app: 'thanos-sidecar' },
|
labels: { prometheus: p.config.name, app: 'thanos-sidecar' },
|
||||||
},
|
},
|
||||||
spec: {
|
spec: {
|
||||||
ports: [
|
ports: [
|
||||||
@ -42,9 +42,9 @@
|
|||||||
prometheus+: {
|
prometheus+: {
|
||||||
spec+: {
|
spec+: {
|
||||||
thanos+: {
|
thanos+: {
|
||||||
version: $._config.versions.thanos,
|
version: $.values.thanos.version,
|
||||||
image: $._config.imageRepos.thanos + ':' + $._config.versions.thanos,
|
image: $.values.thanos.image,
|
||||||
objectStorageConfig: $._config.thanos.objectStorageConfig,
|
objectStorageConfig: $.values.thanos.objectStorageConfig,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
@ -54,7 +54,7 @@
|
|||||||
kind: 'ServiceMonitor',
|
kind: 'ServiceMonitor',
|
||||||
metadata: {
|
metadata: {
|
||||||
name: 'thanos-sidecar',
|
name: 'thanos-sidecar',
|
||||||
namespace: p.namespace,
|
namespace: p.config.namespace,
|
||||||
labels: {
|
labels: {
|
||||||
'app.kubernetes.io/name': 'prometheus',
|
'app.kubernetes.io/name': 'prometheus',
|
||||||
},
|
},
|
||||||
@ -64,7 +64,7 @@
|
|||||||
jobLabel: 'app',
|
jobLabel: 'app',
|
||||||
selector: {
|
selector: {
|
||||||
matchLabels: {
|
matchLabels: {
|
||||||
prometheus: p.name,
|
prometheus: p.config.name,
|
||||||
app: 'thanos-sidecar',
|
app: 'thanos-sidecar',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user