diff --git a/birdhouse/components/monitoring/default.env b/birdhouse/components/monitoring/default.env index c6f781fd..76188073 100644 --- a/birdhouse/components/monitoring/default.env +++ b/birdhouse/components/monitoring/default.env @@ -8,7 +8,7 @@ export GRAFANA_VERSION="7.0.3" export GRAFANA_DOCKER=grafana/grafana export GRAFANA_IMAGE='${GRAFANA_DOCKER}:${GRAFANA_VERSION}' -export PROMETHEUS_VERSION="v2.19.0" +export PROMETHEUS_VERSION="v2.53.3" export PROMETHEUS_DOCKER=prom/prometheus export PROMETHEUS_IMAGE='${PROMETHEUS_DOCKER}:${PROMETHEUS_VERSION}' diff --git a/birdhouse/components/monitoring/prometheus.yml.template b/birdhouse/components/monitoring/prometheus.yml.template index f5d7cd09..737331ed 100644 --- a/birdhouse/components/monitoring/prometheus.yml.template +++ b/birdhouse/components/monitoring/prometheus.yml.template @@ -20,6 +20,9 @@ scrape_configs: - targets: - ${BIRDHOUSE_FQDN}:9100 +scrape_config_files: + - "/etc/prometheus/scrape_config.d/*.yml" + rule_files: - "/etc/prometheus/*.rules" diff --git a/birdhouse/optional-components/prometheus-log-parser/config/monitoring/.gitignore b/birdhouse/optional-components/prometheus-log-parser/config/monitoring/.gitignore new file mode 100644 index 00000000..add998b9 --- /dev/null +++ b/birdhouse/optional-components/prometheus-log-parser/config/monitoring/.gitignore @@ -0,0 +1 @@ +scrape_configs.yml diff --git a/birdhouse/optional-components/prometheus-log-parser/config/monitoring/docker-compose-extra.yml b/birdhouse/optional-components/prometheus-log-parser/config/monitoring/docker-compose-extra.yml new file mode 100644 index 00000000..c16e2f8e --- /dev/null +++ b/birdhouse/optional-components/prometheus-log-parser/config/monitoring/docker-compose-extra.yml @@ -0,0 +1,5 @@ +version: "3.4" +services: + prometheus: + volumes: + - ./optional-components/prometheus-log-parser/config/monitoring/scrape_configs.yml:/etc/prometheus/scrape_config.d/log_parser.yml:ro diff --git a/birdhouse/optional-components/prometheus-log-parser/config/monitoring/scrape_configs.yml.template b/birdhouse/optional-components/prometheus-log-parser/config/monitoring/scrape_configs.yml.template new file mode 100644 index 00000000..025cadc6 --- /dev/null +++ b/birdhouse/optional-components/prometheus-log-parser/config/monitoring/scrape_configs.yml.template @@ -0,0 +1,6 @@ +scrape_configs: + - job_name: log_parser + honor_labels: true + static_configs: + - targets: + - prometheus-log-parser:${PROMETHEUS_LOG_PARSER_CLIENT_PORT} diff --git a/birdhouse/optional-components/prometheus-log-parser/default.env b/birdhouse/optional-components/prometheus-log-parser/default.env index ec7c0820..35e268b4 100644 --- a/birdhouse/optional-components/prometheus-log-parser/default.env +++ b/birdhouse/optional-components/prometheus-log-parser/default.env @@ -6,6 +6,11 @@ export PROMETHEUS_LOG_PARSER_PARSERS_DIR=/parsers.d export PROMETHEUS_LOG_PARSER_POLL_DELAY=1 # time in seconds export PROMETHEUS_LOG_PARSER_TAIL=t +OPTIONAL_VARS=" + $OPTIONAL_VARS + \$PROMETHEUS_LOG_PARSER_CLIENT_PORT +" + export DELAYED_EVAL=" $DELAYED_EVAL PROMETHEUS_LOG_PARSER_IMAGE