Skip to content

Instantly share code, notes, and snippets.

@mgedmin
Last active December 25, 2015 12:39
Show Gist options
  • Save mgedmin/6977710 to your computer and use it in GitHub Desktop.
Save mgedmin/6977710 to your computer and use it in GitHub Desktop.
REMOTE_USER authentication for Sentry 6.3.0
WSGIDaemonProcess sentry display-name=wsgi-sentry user=sentry group=sentry processes=1 threads=4
WSGIScriptAlias / /path/to/sentry.wsgi
<Location />
WSGIApplicationGroup %{GLOBAL}
WSGIProcessGroup sentry
AuthType Basic
AuthName "sentry"
AuthUserFile /path/to/htpasswd
Require valid-user
</Location>
<LocationMatch "^/api(/\d+)?/store/?$">
Allow from all
Satisfy Any
</LocationMatch>
from sentry.conf.server import *
...
# Allow anybody in Apache's htpasswd file to log in
MIDDLEWARE_CLASSES += (
'django.contrib.auth.middleware.RemoteUserMiddleware',
)
AUTHENTICATION_BACKENDS = (
'django.contrib.auth.backends.RemoteUserBackend',
) + AUTHENTICATION_BACKENDS
# Allow anybody who has logged in to view any of the projects
SENTRY_PUBLIC = True
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment