Skip to content

TemplateDoesNotExist: sentry_auth_google/configure.html During Google Auth configuration #13565

@mikhno-s

Description

@mikhno-s

Important Details

How are you running Sentry?

  • On-Premise docker [Version 9.1.1]
  • Saas (sentry.io)
  • Other [briefly describe your environment]

Description

I got an error when I was trying to configure Google OAuth at /organizations/sentry/auth/configure.

I have previous installation v9.0 with sentry-auth-google installing.
And there everything works fine, also I use sentry.conf.py to configure google-auth.
From v9.1 I know, that this package must be integrated in sentry on-premise setup.

Steps to Reproduce

  1. Clone https://github.com/getsentry/onpremise
  2. Add to config.yaml auth-google.client-id and auth-google.client-secret
  3. Add new sentry url and redirect url to allowed in google oauth console configuration
  4. Running next steps https://github.com/getsentry/onpremise#up-and-running, create superuser during migrations
  5. Login with superuser credentials, set Root URL
  6. Go to /settings/sentry/auth/ and click Configure in front of Google provider
  7. Redirecting to google login form, login and redirect to organizations/sentry/auth/configure/
  8. Get an error Oops! Something went wrong.

What you expected to happen

I wish I would see usual page with google auth configuring

Stacktrace

web_1        | 11:57:37 [INFO] sentry.superuser: superuser.request (user_id=1 url=u'http://sentry.myhost.com/organizations/sentry/auth/configure/' ip_address=u'172.21.0.1' method=u'GET')
web_1        | Traceback (most recent call last):
web_1        |   File "/usr/local/lib/python2.7/site-packages/django/core/handlers/base.py", line 112, in get_response
web_1        |     response = wrapped_callback(request, *callback_args, **callback_kwargs)
web_1        |   File "/usr/local/lib/python2.7/site-packages/django/views/generic/base.py", line 69, in view
web_1        |     return self.dispatch(request, *args, **kwargs)
web_1        |   File "/usr/local/lib/python2.7/site-packages/django/views/decorators/csrf.py", line 57, in wrapped_view
web_1        |     return view_func(*args, **kwargs)
web_1        |   File "/usr/local/lib/python2.7/site-packages/sentry/web/frontend/base.py", line 225, in dispatch
web_1        |     return self.handle(request, *args, **kwargs)
web_1        |   File "/usr/local/lib/python2.7/site-packages/django/db/transaction.py", line 371, in inner
web_1        |     return func(*args, **kwargs)
web_1        |   File "/usr/local/lib/python2.7/site-packages/sentry/web/frontend/organization_auth_settings.py", line 186, in handle
web_1        |     auth_provider=auth_provider,
web_1        |   File "/usr/local/lib/python2.7/site-packages/sentry/web/frontend/organization_auth_settings.py", line 138, in handle_existing_provider
web_1        |     'provider': provider,
web_1        |   File "/usr/local/lib/python2.7/site-packages/sentry/plugins/base/response.py", line 37, in render
web_1        |     return render_to_string(self.template, context, request)
web_1        |   File "/usr/local/lib/python2.7/site-packages/sentry/web/helpers.py", line 115, in render_to_string
web_1        |     return loader.render_to_string(template, context)
web_1        |   File "/usr/local/lib/python2.7/site-packages/django/template/loader.py", line 162, in render_to_string
web_1        |     t = get_template(template_name)
web_1        |   File "/usr/local/lib/python2.7/site-packages/django/template/loader.py", line 138, in get_template
web_1        |     template, origin = find_template(template_name)
web_1        |   File "/usr/local/lib/python2.7/site-packages/django/template/loader.py", line 131, in find_template
web_1        |     raise TemplateDoesNotExist(name)
web_1        | TemplateDoesNotExist: sentry_auth_google/configure.html
web_1        | 11:57:37 [ERROR] django.request: Internal Server Error: /organizations/sentry/auth/configure/ (status_code=500 request=<WSGIRequest: GET u'/organizations/sentry/auth/configure/'>)
web_1        | 172.21.0.1 - - [05/Jun/2019:11:57:37 +0000] "GET /organizations/sentry/auth/configure/ HTTP/1.1" 500 7349 "http://sentry.myhost.com/settings/sentry/auth/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/74.0.3729.169 Safari/537.36"

Possible Solution

The root is TemplateDoesNotExist: sentry_auth_google/configure.html
Maybe, django template for this page should be installed as well.

Metadata

Metadata

Assignees

Labels

No labels
No labels
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions