Alerting is part of cluster monitoring, where alert notifications are sent to the configured email or slack channel
Prometheus, Grafana, and alert manager tools are needed to set up alert notifications. Install monitoring.
- Creating slack incoming webhook here,
- Create a slack application for your environment from the above url.
- After creating the app select
Incoming webhooksfromFeaturessection. - Then Activate Incoming webhooks.
- Then select
Add New Webhook To Workspaceand choose a slack channel where the alerts need to be notified. - Then Incoming webhook url will be created.
- update
slack_api_urlandchannelinalertmanager.yaml - run
./install.shto patch alertmanager.
The monitoring package provided by rancher has various default alerting rules, most of the time the default rules are enough. Sample custom alerts are provided under custom-alerts. Modify the same and apply using kubectl
- Go to alertmanager under monitoring tab in rancher ui
- Click on the alert -> silence, add appropriate silence duration, creator, and comment
When having multiple clusters, you can add a cluster name to be presented as part of alert information. Here our cluster name is soil.
- Add cluster name in,
patch-cluster-name.yaml - Run
install.sh

