Skip to content
This repository has been archived by the owner on Oct 19, 2024. It is now read-only.

docs: sync slack integration docs #418

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 23 additions & 1 deletion docs/services/slack.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ The Slack notification service configuration includes following settings:
```

1. Define service type slack in data section of `argocd-notifications-cm` configmap:
service

```yaml
apiVersion: v1
kind: ConfigMap
Expand All @@ -60,6 +60,26 @@ service
notifications.argoproj.io/subscribe.on-sync-succeeded.slack: my_channel
```

1. Annotation with more than one trigger multiple of destinations and recipients

```yaml
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
annotations:
notifications.argoproj.io/subscriptions: |
- trigger: [on-scaling-replica-set, on-rollout-updated, on-rollout-step-completed]
destinations:
- service: slack
recipients: [my-channel-1, my-channel-2]
- service: email
recipients: [recipient-1, recipient-2, recipient-3 ]
- trigger: [on-rollout-aborted, on-analysis-run-failed, on-analysis-run-error]
destinations:
- service: slack
recipients: [my-channel-21, my-channel-22]
```

## Templates

Notification templates can be customized to leverage slack message blocks and attachments
Expand Down Expand Up @@ -145,3 +165,5 @@ template.app-sync-failed: |
groupingKey: "{{.app.status.sync.revision}}"
notifyBroadcast: true
```

The message is sent according to the `deliveryPolicy` string field under the `slack` field. The available modes are `Post` (default), `PostAndUpdate`, and `Update`. The `PostAndUpdate` and `Update` settings require `groupingKey` to be set.