Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support connecting multiple Slack workspaces #1414

Open
michabbb opened this issue Apr 5, 2022 · 19 comments
Open

Support connecting multiple Slack workspaces #1414

michabbb opened this issue Apr 5, 2022 · 19 comments

Comments

@michabbb
Copy link

michabbb commented Apr 5, 2022

Version

22.1.0

Steps to Reproduce

first to understand the confusion: the sentry website says:

image

setup the slack integration as explained in the docs.
setup the slack integration for a different slack workspace.

and here the problem already starts, because the sentry config needs:

slack.client-id: 'xxxxxx'
slack.client-secret: 'xxxxx'
slack.signing-secret: 'xxxxxx'
## If legacy-app is True use verfication-token instead of signing-secret
slack.verification-token: 'xxxxxx'

and I can only add ONE set of ids here, not more.

so either the text on the website is wrong or I am missing something here.

is a 2nd workspace really possible or is the text wrong ? 😏

Expected Result

when connecting the slack workspace with sentry, at the oauth page I should see a drop-down to choose which workspace I want to connect

Actual Result

there is no option to select the slack workspace, because of the fixed config sentry always wants to connect to the only one workspace that seems connected with the "client-id".

@chadwhitacre
Copy link
Member

is a 2nd workspace really possible or is the text wrong ?

Maybe it's a limitation of self-hosted vs. SaaS? I've dropped a line internally with the Ecosystem team to see if they can shed light.

@michabbb
Copy link
Author

@chadwhitacre any updates from the team?

@ngatti-asso
Copy link

I'm also trying to do add more workspaces. Once I had the first workspace working, I tried to add a second one by replacing

slack.client-id: 'xxxxxx'
slack.client-secret: 'xxxxx'
slack.signing-secret: 'xxxxxx'

But it broke the first workspace.

Can you confirm if this is a self-hosted limitation?

Thanks.

@michabbb
Copy link
Author

just FYI - you cannot use the full functionality of slack with multiple workspaces, like "mark an issue as resolved inside slack", but at least you can enable slack-notifications to multiple slack-workspaces, it´s a hack and it´s very sad, that nobody thought about supporting multiple workspaces. it makes no sense having multiple "organizations" in sentry but only being able to use one slack workspace ;) usually every organization has it´s own slack workspace (of course).

so here´s the simple hack, similar to what @ngatti-asso explained:

(1)

  • add the necessary keys to the config (slack.client-id .....)
  • create a new app in slack (follow the docu)
  • add your slack workspace in sentry

(2)

  • just create a new set of config keys in the sentry config, don´t worry, the first set and your first workspace will not (fully) work while you have a 2nd pair of configs in your sentry config, because the 2nd IDs are overwriting the first set of slack IDs
  • add the necessary keys to the config (slack.client-id .....)
  • create a new app in your 2nd slack workspace (follow the docu)
  • add your slack workspace in sentry (as you did before)

(3)
disable the 2nd pair of slack-ids in the sentry config, restart sentry

with this, you will get:

for (1) you will have the full functionality with slack:

  • sentry -> slack
  • sentry <- slack

with (2) you will "only" have:

  • sentry -> slack

better than nothing 😕

@ngatti-asso
Copy link

I confirm that @michabbb setup is working as detailed. It's enough for my current needs as I only needed to send slack notifications to different workspaces.

Thank you!

@michabbb
Copy link
Author

anyway... I am bagging the sentry team to overthink this whole concept 🙏 there shouldn´t be any technical no-gos, because slack push notifications (that go to sentry) should include all necessary data, so that sentry should be 100% able to identify which workspace is talking here and which issue inside sentry is going to be triggered. it may sound trivial from my point of view, but having a sentry config like:

1.slack.client-id: 'xxxxxx'
1.slack.client-secret: 'xxxxx'
1.slack.signing-secret: 'xxxxxx'
2.slack.client-id: 'xxxxxx'
2.slack.client-secret: 'xxxxx'
2.slack.signing-secret: 'xxxxxx'
3.slack.client-id: 'xxxxxx'
3.slack.client-secret: 'xxxxx'
3.slack.signing-secret: 'xxxxxx'

and request URLs like:

{YOUR_DOMAIN}/extensions/slack/action/1/
{YOUR_DOMAIN}/extensions/slack/action/2/
{YOUR_DOMAIN}/extensions/slack/action/3/

maybe could do the trick... just a naive suggestion 😏

@chadwhitacre
Copy link
Member

I dropped another line internally (hopefully in a better channel now 😅) ... sorry this is falling through the cracks a bit, glad @ngatti-asso has at least joined you here @michabbb. 😁

@scefali
Copy link
Contributor

scefali commented Apr 12, 2022

@chadwhitacre @michabbb So the issue has to do with how apps are published. Since Sentry is a published app for Slack, anyone can install it to any workspace. But since your internal app is not published, you can only install it on the workspace it was created on. So the text you see is correct for SaaS Sentry but not correct for self-hosted in that self-hosted Sentry can only connect to one Slack workspace.

@michabbb
Copy link
Author

michabbb commented Apr 12, 2022

@scefali i don´t see any reason why someone should have done this by purpose. that makes absolutely no sense. is this done as a wanted limitation to force people into SaaS ? 🤔 and again: technically there is no reason and no problem (in my eyes) to make this working with multiple slack workspaces, the design concept here is just "wrong". having only one "slack.client-id" and only one "request URL" is the main problem here and could easily be solved (I hope) with a suggestion like I made. again, I don´t know the internals, but if this is not done with the intention to push people into SassS, this should be "fixed", because having multiple organizations but only one workspace, is against every business logic.

@chadwhitacre
Copy link
Member

It does appear that Sentry assumes it will be talking to a single app, so we should tweak some documentation at the very least.

@michabbb Can you publish your app? I am not familiar with Slack's review process—is this an option?

@michabbb
Copy link
Author

@chadwhitacre first: i strongly hope, that a fix is not seen as "changing the documentation" 😂 that wouldn´t solve the "failed by concept" problem here 😏 secondly: what do you mean with "publish your app" ? every workspace owner just creates a "custom app" as explained in the docs. that is not a "official published" app. it´s a "custom app, only available inside your workspace". and that is the point. every slack workspace owner is able to create this app, as he likes. everybody is able to choose his own name, logo... whatever.

but sentry currently is false designed by that fact, that there is only one slack.client-id and only one central request-url, that´s the problem here.

because of the slack.client-id : when you try to connect sentry with slack, sentry creates slack login URL, that is already bounded to the workspace, that is connected with this slack.client-id. that´s the main problem in my eyes.

usually, when you connect something with slack, you see a drop-down in the top right where you can choose, which slack-workspace you want to connect, but this is excluded in the first place here:

image

and because - I guess - sentry only allows "one request/callback URL" - there is currently no chance to distinguish between different workspaces.

again: slack-ids and request-urls should be arrays, and when trying to connect to slack - sentry should ask you, based on the number of workspaces you have setup in the sentry-config, to which workspace you want to connect and then sentry can - as it´s working right now - create a specific login-url for a specific workspace 😏

@github-actions
Copy link

github-actions bot commented May 4, 2022

This issue has gone three weeks without activity. In another week, I will close it.

But! If you comment or otherwise update it, I will reset the clock, and if you label it Status: Backlog or Status: In Progress, I will leave it alone ... forever!


"A weed is but an unloved flower." ― Ella Wheeler Wilcox 🥀

@michabbb
Copy link
Author

michabbb commented May 4, 2022

@chadwhitacre can u please give us an update here? I really hope the team understands, that sentry, doesn't matter, if self hosted or SaaS, needs to be able to work with multiple slack workspaces together, to make sentry useful when it comes to using multiple organizations, otherwise the whole slack thing is quite useless. 😕

@chadwhitacre
Copy link
Member

Putting this on the backlog so the bot won't close. Best I can do for now.

@getsentry getsentry locked and limited conversation to collaborators May 13, 2022
@chadwhitacre chadwhitacre converted this issue into a discussion May 13, 2022
@getsentry getsentry unlocked this conversation Jun 17, 2022
@chadwhitacre chadwhitacre reopened this Jun 17, 2022
@vbezruchkin
Copy link

hi,

Does everyone have any success in connecting Sentry instance to several Slack workspaces?

@michabbb
Copy link
Author

@vbezruchkin as already explained, there is a hack where the 2nd (or more) workspaces only can receive sentry notifications, but slack is not able to talk back.

@chadwhitacre is there any update here?

@chadwhitacre chadwhitacre changed the title Sentry says "Connect your Sentry organization to one OR MORE Slack workspaces" but more than one seems to be impossible Support connecting an org to multiple Slack workspaces Nov 30, 2022
@chadwhitacre
Copy link
Member

@michabbb No great news for you, no. Our product team responsible for the Slack integration prioritizes issues related to our SaaS environment, so while I could push this to their backlog I expect that will be an endless wait. Instead I've adjusted the title (accurately, yes?) and linked this in my team's quarterly planning brainstorm. I think we're more likely to be able to eventually prioritize the work on our team, assuming someone from the community doesn't step up to make the attempt first. Not the update you want, but it's the one I've got. 🙏

@michabbb
Copy link
Author

@chadwhitacre nope, sorry, the title is completely wrong. it's not about connection multiple slack workspaces inside one org, it's about connection multiple slack workspaces in general, because it's not possible to connect more than one, that has nothing to do with sentry org.

although the real world use would be:

every sentry org should have its own slack connection

and the ultimate solution/freedom would be, to connect every project to its own slack workspace.

but hey, we would be happy (in the first place) if every org could have its own slack connection. 😏

so the current implementation is broken. I can have multiple orgs in sentry but only one slack connection, system wide. that makes no sense.

thanks,
Micha

@chadwhitacre chadwhitacre changed the title Support connecting an org to multiple Slack workspaces Support connecting multiple Slack workspaces Nov 30, 2022
@naustra
Copy link

naustra commented Sep 8, 2024

+1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: No status
Status: No status
Development

No branches or pull requests

7 participants