Settings > Auth > Authentication
CHOOSE A PROVIDER
[Where are the rest of the providers they should be here I think?] (In particular Bitbucket)
Settings > Auth > Authentication
CHOOSE A PROVIDER
[Where are the rest of the providers they should be here I think?] (In particular Bitbucket)
I guess you are looking for this: https://docs.sentry.io/server/sso/#enabling-sso
That said I’m not aware of an up-to-date BitBucket SSO integration. I found this which is quite old: https://github.com/neilalbrock/sentry-bitbucket
I followed your guide and just to test it added to /etc/sentry/sentry.conf.py:
SENTRY_FEATURES[‘organizations:sso’] = False
I restarted the service.
I logged out and back in again and the auth tab remains (it should have disappeared)
This provider is in the source already without installing any plugins.
./lib/python2.7/site-packages/sentry/identity/ bitbucket /provider.py
I can see the auth backends are in config:
‘AUTHENTICATION_BACKENDS’: (‘sentry.utils.auth.EmailAuthBackend’,
‘social_auth.backends.github.GithubBackend’,
‘social_auth.backends.github_apps.GithubAppsBackend’,
‘social_auth.backends.bitbucket.BitbucketBackend’,
‘social_auth.backends.trello.TrelloBackend’,
‘social_auth.backends.asana.AsanaBackend’,
‘social_auth.backends.slack.SlackBackend’,
‘social_auth.backends.visualstudio.VisualStudioBackend’),
There are many auth providers in the source code. I cannot see any of them (apart from Google Apps) them in the website auth tab.
Aha, found it! - https://github.com/getsentry/sentry/blob/f640668b833fe4fb9e46edb9a9d89748adb4555d/src/sentry/conf/server.py#L456-L469
Looks like you need to set BITBUCKET_CONSUMER_KEY
and BITBUCKET_CONSUMER_SECRET
in your config for this to show up. Apologies for the lacking documentation around this. I’ll take note to add this to our docs.
Please report back whether this works nicely or not
BITBUCKET_CONSUMER_KEY = ‘xxxxxxxxxxxx’
BITBUCKET_CONSUMER_SECRET = ‘xxxxxxxxx’
These are now set in sentry.conf.py
However there is no Bitbucket logo or option to login via Bitbucket. If I use the Bitbucket credentials (email and password) associated with the Bitbucket auth provider (that has this key and secret) I still cannot login.
Which version are you using and what installation method have you used?
I am using the Python method from the documentation. Sentry 9.1.2.
@rmurdoch I’m assuming you have restarted Sentry after changing the config, right? I can’t really think of anything as this line should enable it once these values are set: https://github.com/getsentry/sentry/blob/0fffc30f1455a23f98e76240fb1bf9de7ef81e71/src/social_auth/backends/init.py#L368-L373