diff --git a/docker-compose.yml b/docker-compose.yml index 10e332e3a159b796a145f0a1defe019895960bc4..f49b77959a0e603bd536009fc6c1be2d5a7bf682 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -78,3 +78,12 @@ services: - proxy-tier depends_on: - proxy + + prometheus: + image: prom/prometheus + container_name: prometheus + ports: + - 127.0.0.1:9090:9090 + volumes: + - ./prometheus.yml:/etc/prometheus/prometheus.yml + diff --git a/prometheus.yml b/prometheus.yml new file mode 100644 index 0000000000000000000000000000000000000000..bfe4d04da5a7fbfee25774c9f5a18d90b6672bad --- /dev/null +++ b/prometheus.yml @@ -0,0 +1,28 @@ +# my global config +global: + scrape_interval: 15s + evaluation_interval: 15s + +# Alertmanager configuration +alerting: + alertmanagers: + - static_configs: + - targets: + # - alertmanager:9093 + +# Load rules once and periodically evaluate them according to the global 'evaluation_interval'. +rule_files: + # - "first_rules.yml" + # - "second_rules.yml" + +# 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=<job_name>` to any timeseries scraped from this config. + - job_name: 'prometheus' + + # metrics_path defaults to '/metrics' + # scheme defaults to 'http'. + + static_configs: + - targets: ['localhost:9090']