122 lines
4.2 KiB
JSON
122 lines
4.2 KiB
JSON
{
|
|
"apiVersion": "v1",
|
|
"kind": "ReplicationController",
|
|
"metadata": {
|
|
"labels": {
|
|
"name": "kube-prometheus"
|
|
},
|
|
"name": "kube-prometheus"
|
|
},
|
|
"spec": {
|
|
"replicas": 1,
|
|
"selector": {
|
|
"name": "kube-prometheus"
|
|
},
|
|
"template": {
|
|
"metadata": {
|
|
"labels": {
|
|
"name": "kube-prometheus"
|
|
}
|
|
},
|
|
"spec": {
|
|
"containers": [
|
|
{
|
|
"image": "prom/promdash",
|
|
"name": "kube-promdash",
|
|
"env": [
|
|
{
|
|
"name": "DATABASE_URL",
|
|
"value": "sqlite3:/promdash/file.sqlite3"
|
|
}
|
|
],
|
|
"ports": [
|
|
{
|
|
"containerPort": 3000,
|
|
"hostPort": 3000,
|
|
"protocol": "TCP"
|
|
}
|
|
],
|
|
"volumeMounts": [
|
|
{
|
|
"mountPath": "/promdash",
|
|
"name": "data"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"image": "jayunit100/kube-prometheus",
|
|
"name": "kube-prometheus",
|
|
"command": [
|
|
"./run_prometheus.sh",
|
|
"-t",
|
|
"KUBERNETES_RO,PUSHGATEWAY",
|
|
"-d",
|
|
"/var/prometheus/"
|
|
],
|
|
"env": [
|
|
{
|
|
"name": "KUBERNETES_RO_SERVICE_HOST",
|
|
"value": "localhost"
|
|
},
|
|
{
|
|
"name": "KUBERNETES_RO_SERVICE_PORT",
|
|
"value": "8001"
|
|
},
|
|
{
|
|
"name": "PUSHGATEWAY_SERVICE_HOST",
|
|
"value": "localhost"
|
|
},
|
|
{
|
|
"name": "PUSHGATEWAY_SERVICE_PORT",
|
|
"value": "9091"
|
|
}
|
|
],
|
|
"ports": [
|
|
{
|
|
"containerPort": 9090,
|
|
"hostPort": 9090,
|
|
"protocol": "TCP"
|
|
}
|
|
],
|
|
"volumeMounts": [
|
|
{
|
|
"mountPath": "/var/prometheus/",
|
|
"name": "data"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"image": "jayunit100/prompush:0.2.0",
|
|
"name": "pushgateway",
|
|
"ports": [
|
|
{
|
|
"containerPort": 9091,
|
|
"hostPort": 9091,
|
|
"protocol": "TCP"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"image": "gcr.io/google_containers/kubectl:v0.18.0-350-gfb3305edcf6c1a",
|
|
"name": "kubectl",
|
|
"args": [
|
|
"proxy",
|
|
"-p",
|
|
"8001",
|
|
"--api-prefix=/"
|
|
]
|
|
}
|
|
],
|
|
"volumes": [
|
|
{
|
|
"hostPath": {
|
|
"path": "/mnt/promdash"
|
|
},
|
|
"name": "data"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
}
|