Skip to main content

Drift detection notifications per stack owner or team label

Ability to route drift notifications based on stack level metadata.
For example, each stack could have a label or owner field that maps to a Slack channel, alias or user list. When drift is detected, the system would send a notification directly to the right team instead of relying on a single global webhook. This is especially important where many teams own their own stacks.

Status: ✅ Completed1 comment

Log in to comment and vote

Comments1

  • Danielle Murphy

    Team•

    Jan 21

    Hi, Danielle from support here - this is already possible today using notification policies and stack-level metadata.

    We have an example policy that routes Slack notifications based on stack labels, which allows you to map ownership or team labels directly to specific Slack channels:
    https://github.com/spacelift-io/spacelift-policies-example-library/blob/main/examples/notification/slack-channels-with-labels.rego

    In practice, each stack can define a label and the notification policy uses that label to determine the appropriate Slack channel when drift is detected - avoiding reliance on generic channels.

    If you prefer using human-readable names instead of Slack channel IDs, you can maintain a simple mapping inside the policy (e.g. team name → channel ID) and reference only the name in the stack label.