Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Message: Not Found] using uir static or dynamic. No Alerts are send to Teams channel #340

Open
jadatoin opened this issue Aug 15, 2023 · 0 comments
Labels
bug Something isn't working

Comments

@jadatoin
Copy link

Describe the bug
Hi, sorry for bother but I will need some help.
Our prometheus-msteams configuration was deployed and the tests are working, but using static/dynamic uri I got message: "Not Found" on each.
Version
OS: Ubuntu 22.04.03
Binary Prometheus-MSTeams v1.5.2
Binary Alertmanager v0.25.0

Test
curl -X POST -d @prom-alert.json http://myfqdn.dom:2000/_dynamicwebhook/ (Works)
curl -X POST -d @prom-alert.json http://myfqdn.dom:2000/alertmanager/ (Works)

Config Parts
Service Daemon:

[Unit]
Description=Prometheus-msteams
Wants=network-online.target
After=network-online.target

[Service]
User=root
Group=
Type=simple
ExecStart=/opt/prometheus-msteams/prometheus-msteams -teams-request-uri alertmanager \
          -http-addr myfqdn.dom:2000 -config-file /opt/prometheus-msteams/config.yml \
          -template-file /opt/prometheus-msteams/card.tmpl

prometheus-msteams config (config.yml):

connectors:
  - alertmanager: "https://myO365.webhook.link/aaa/bbb/vvv/xxx"

Alertmanager config (alertmanager.yml)

receivers:
  - name: alert_channel
    webhook_configs:
      - send_resolved: true
        url: 'http://myfdn.dom:2000/alertmanager'
route:
  group_by: ['alertname','severity']
  group_wait: 1m
  group_interval: 15m
  repeat_interval: 1h
  routes:
   - match:
      severity: warning
     receiver: alert_channel

   - match:
      severity: critical
     receiver: alert_channel

templates:
- '/etc/prometheus/alertmanager_templates/*_alert.tmpl'

Prometheus config:

global:
  scrape_interval: 15s 
  evaluation_interval: 15s 

# Alertmanager configuration
alerting:
  alertmanagers:
  - static_configs:
    - targets:
      - 'myfqdn.dom:9093'

rule_files:
   - '/etc/prometheus/alert.rules.yml'

Expected behavior
I expected having the alerts incoming into MSTeams and emails. But only receiving alert mails, prometheus-msteams is not sending msgs to Teams Channel. How I can check logs? and any idea if something is wrong with my config.

Thanks for any help.

@jadatoin jadatoin added the bug Something isn't working label Aug 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant