Overview

Alertmanager needs credentials for each platform before it can send notifications. This page walks through getting those credentials step by step.

After getting all credentials, add them to terraform.tfvars:

slack_webhook_url   = "https://hooks.slack.com/services/..."
telegram_bot_token  = "xxxxxxxxx:AAH..."
telegram_chat_id    = "123456789"
discord_webhook_url = "https://discord.com/api/webhooks/.../slack"
gmail_app_password  = "xxxx xxxx xxxx xxxx"

Then apply:

export SSL_CERT_FILE=$(python3 -c "import certifi; print(certifi.where())")
terraform apply -target=helm_release.kube_prometheus_stack -auto-approve

1. Gmail App Password

Gmail requires an App Password - your regular Gmail password won't work with SMTP.

  1. Go to myaccount.google.com
  2. Security → 2-Step Verification (must be enabled)
  3. Search "App Passwords" at the top
  4. Select app: Mail → Select device: Other → name it Alertmanager
  5. Copy the 16-character password (format: xxxx xxxx xxxx xxxx)

Add to terraform.tfvars:

gmail_app_password = "xxxx xxxx xxxx xxxx"

2. Slack

Create a Slack App