X-Git-Url: https://osm.etsi.org/gitweb/?a=blobdiff_plain;f=installers%2Fdocker%2Fosm_pods%2Fprometheus.yaml;fp=installers%2Fdocker%2Fosm_pods%2Fprometheus.yaml;h=2610710f4a78de0893ca4c7fea7ef5c3df17a77f;hb=09eaa9263cfd3f0eaf3c10d756a781ee241cb5e6;hp=ac3a5240aa5b8a9429c16ea9f5fb2aa810c03062;hpb=d2772ad7d595c59fc9d06e83cbc11b8172fc3495;p=osm%2Fdevops.git diff --git a/installers/docker/osm_pods/prometheus.yaml b/installers/docker/osm_pods/prometheus.yaml index ac3a5240..2610710f 100644 --- a/installers/docker/osm_pods/prometheus.yaml +++ b/installers/docker/osm_pods/prometheus.yaml @@ -73,15 +73,12 @@ data: # A scrape configuration containing exactly one endpoint to scrape: # Here it's Prometheus itself. - scrape_configs: - # The job name is added as a label `job=` to any timeseries scraped from this config. - - job_name: 'mon_exporter' - - # metrics_path defaults to '/metrics' - # scheme defaults to 'http'. - - static_configs: - - targets: ['mon:8000'] + scrape_configs: [] + # scrape_configs: + # Add here other external targets, e.g. a pushgateway + # - job_name: 'pushgateway' + # static_configs: + # - targets: ['prometheus-pushgateway:9091'] kind: ConfigMap metadata: name: prom @@ -107,12 +104,12 @@ spec: - name: prometheus-init-config image: busybox command: ["/bin/sh", "-c"] - args: ['if [ ! -f "/etc/prometheus/prometheus.yml" ]; then cp /etc/prometheus_init/prometheus.yml /etc/prometheus; fi'] + args: ['if [ ! -f "/etc/prometheus/prometheus.yml" ]; then cp /config/prometheus.yml /etc/prometheus; fi'] volumeMounts: - name: prom-config mountPath: /etc/prometheus - - name: init-prom-config - mountPath: /etc/prometheus_init + - name: prom-config-base + mountPath: /config containers: - name: prometheus image: prom/prometheus:v2.28.1 @@ -134,6 +131,8 @@ spec: value: mongodb://mongodb-k8s:27017/?replicaSet=rs0 - name: PROMETHEUS_CONFIG_FILE value: /etc/prometheus/prometheus.yml + - name: PROMETHEUS_BASE_CONFIG_FILE + value: /etc/prometheus_base/prometheus.yml - name: TARGET_DATABASE value: osm - name: PROMETHEUS_URL @@ -141,11 +140,13 @@ spec: volumeMounts: - name: prom-config mountPath: /etc/prometheus + - name: prom-config-base + mountPath: /etc/prometheus_base volumes: - - emptyDir: {} - name: prom-db + - name: prom-db + emptyDir: {} - name: prom-config emptyDir: {} - - name: init-prom-config + - name: prom-config-base configMap: name: prom