Instalei os plugins discourse e discourse-prometheus, depois adicionei a seguinte configuração em prometheus.yaml:
- job_name: forums
metrics_path: /metrics
static_configs:
- targets:
- forums.kingsd.top
scheme: https
basic_auth:
username: admin
password: password
Em seguida, descobri que o status do Endpoint correspondente no prometheus estava sempre DOWN, e o log de erro server returned HTTP status 404 Not Found apareceu.
O seguinte log de erro continua aparecendo em shared/standalone/log/rails/production.log:
Started GET "/metrics" for 123.184.31.122 at 2022-03-17 11:03:34 +0000
ActionController::RoutingError (No route matches [GET] "/metrics")
config/initializers/100-quiet_logger.rb:23:in `call'
config/initializers/100-silence_logger.rb:31:in `call'
lib/middleware/enforce_hostname.rb:23:in `call'
lib/middleware/request_tracker.rb:202:in `call'
Rendered exceptions/not_found.html.erb within layouts/no_ember (Duration: 0.3ms | Allocations: 193)
Rendered layout layouts/no_ember.html.erb (Duration: 4.1ms | Allocations: 2216)
Rendered html template (Duration: 0.0ms | Allocations: 2)
Há algo de errado com a minha configuração? Por favor, ajude-me.
