flagger icon indicating copy to clipboard operation
flagger copied to clipboard

Slack bot token authentication

Open RicardoLorenzo opened this issue 3 years ago • 3 comments

Adding Bearer token for using Slack apps instead of webhook as recommended by Slack and also used in Flux.

RicardoLorenzo avatar Sep 21 '22 15:09 RicardoLorenzo

@RicardoLorenzo can you please document this feature in https://github.com/fluxcd/flagger/blob/main/docs/gitbook/usage/alerting.md Thanks!

stefanprodan avatar Sep 21 '22 15:09 stefanprodan

Codecov Report

Base: 54.68% // Head: 54.66% // Decreases project coverage by -0.02% :warning:

Coverage data is based on head (b116014) compared to base (89b0487). Patch coverage: 58.82% of modified lines in pull request are covered.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1270      +/-   ##
==========================================
- Coverage   54.68%   54.66%   -0.03%     
==========================================
  Files          81       81              
  Lines        6965     6972       +7     
==========================================
+ Hits         3809     3811       +2     
- Misses       2559     2562       +3     
- Partials      597      599       +2     
Impacted Files Coverage Δ
pkg/notifier/client.go 29.72% <0.00%> (-1.70%) :arrow_down:
pkg/notifier/factory.go 0.00% <0.00%> (ø)
pkg/controller/events.go 50.80% <50.00%> (-0.44%) :arrow_down:
pkg/notifier/slack.go 76.47% <80.00%> (+0.71%) :arrow_up:
pkg/notifier/discord.go 72.22% <100.00%> (ø)
pkg/notifier/gchat.go 88.88% <100.00%> (ø)
pkg/notifier/rocket.go 75.75% <100.00%> (ø)
pkg/notifier/teams.go 76.92% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

codecov-commenter avatar Sep 21 '22 15:09 codecov-commenter

@RicardoLorenzo can you please document this feature in https://github.com/fluxcd/flagger/blob/main/docs/gitbook/usage/alerting.md Thanks!

Thank you! documentation added.

RicardoLorenzo avatar Sep 21 '22 15:09 RicardoLorenzo

Thanks @stefanprodan . I do have a Slack app indeed we used for this.

For your peace of mind, this is also referenced in here. The following works which is what we are doing here.

curl https://slack.com/api/conversations.list -H "Authorization: Bearer xoxb-1234..."

Thanks again!

RicardoLorenzo avatar Oct 18 '22 14:10 RicardoLorenzo