prometheus / prometheus/alertmanager

Alertmanager does not load everything needed for notifiers on startup

Open
#4,994 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

component/config keepalive
Dominant language
Go
Stars
8.6k
Forks
2.5k
Avg merge
2d 6h
Merged PRs (30d)
61

Description

What did you do?

Deployed an alertmanager configuration with url_file, that does not exist.

❯ cat /etc/alertmanager/webhook-url.txt
cat: /etc/alertmanager/webhook-url.txt: No such file or directory
What did you expect to see?

Alertmanager should not start or reload the configuration.

What did you see instead? Under which circumstances?

Alertmanager loads the configuration without an error, and only exposes the error upon sending an alert.

System information

No response

Alertmanager version

Alertmanager configuration file
route:
  receiver: 'webhook-from-file'

receivers:
  - name: 'webhook-from-file'
    webhook_configs:
      - url_file: '/etc/alertmanager/webhook-url.txt'
Prometheus version

Prometheus configuration file

Logs

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with Alertmanager's configuration loading and notifier initialization paths, using the provided YAML with a missing url_file to reproduce the behavior. Done means startup and configuration reload reject the invalid notifier configuration with an error instead of deferring the error until an alert is sent.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
devops, observability-sre
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.