X-Git-Url: https://osm.etsi.org/gitweb/?a=blobdiff_plain;f=installers%2Fdocker%2Fosm_pods%2Fprometheus.yaml;h=a914ea535b6789f1d4753b0095086352677e3f6a;hb=89c5f55fc5fe30e9f38ef079ebf27ac996183d61;hp=431b9b3fa94ed0300532fca55635cf3ae3b227cd;hpb=c973b57b1f34ecb64f248f3098ac7b79c1b8a0ae;p=osm%2Fdevops.git diff --git a/installers/docker/osm_pods/prometheus.yaml b/installers/docker/osm_pods/prometheus.yaml index 431b9b3f..a914ea53 100644 --- a/installers/docker/osm_pods/prometheus.yaml +++ b/installers/docker/osm_pods/prometheus.yaml @@ -74,14 +74,13 @@ 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'] + # Add here other external targets, e.g. a pushgateway + # - job_name: 'pushgateway' + # static_configs: + # - targets: ['prometheus-pushgateway:9091'] kind: ConfigMap metadata: name: prom @@ -107,15 +106,15 @@ 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.4.3 + image: prom/prometheus:v2.28.1 args: - --config.file=/etc/prometheus/prometheus.yml - --web.enable-lifecycle @@ -128,12 +127,14 @@ spec: - name: prom-db mountPath: /prometheus - name: prometheus-config-sidecar - image: opensourcemano/prometheus:11 + image: opensourcemano/prometheus:13 env: - name: MONGODB_URL 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 +142,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