Skip to content

Post alert messages to Slack

Nick Malcolm requested to merge 7-slack-alerter into main

Closes #7 (closed)

Example

Screenshot_2023-10-31_at_9.09.23_PM

If you want to play around with Slack's Block Builder here is the link for the message I made.

Steps to use locally

You need a PAT, the Slack token, and a channel to post to. With that:

GITLAB_API_PRIVATE_TOKEN=$(op item get "Mr Cid" --fields="credential") \
SLACK_BOT_OAUTH_TOKEN=$(op item get "Slack App Credentials" --fields="bot_token") \
./bin/mr_cid.rb \
  --since="2023-10-19T00:00Z" \
  --project_path="gitlab-com/gl-security/appsec/tooling/confidential-issue-detector-test-project/project" \
  --outputs=text,slack \
  --slack_channel=C0646GHD2BS
Edited by Nick Malcolm

Merge request reports