add sentry

This commit is contained in:
2019-01-19 05:58:03 +03:00
parent 87e6055b77
commit b673cb53cb
3 changed files with 9 additions and 0 deletions

View File

@@ -1,6 +1,7 @@
import os
import environ
import raven
BASE_DIR = environ.Path(__file__) - 2
@@ -22,6 +23,7 @@ INSTALLED_APPS = [
'django.contrib.messages',
'django.contrib.staticfiles',
'raven.contrib.django.raven_compat',
'django_extensions',
'bootstrap4',
@@ -89,3 +91,8 @@ MEDIA_ROOT = str(PUBLIC_ROOT.path('uploads'))
LOGIN_URL = 'cabinet:login'
LOGIN_REDIRECT_URL = 'cabinet:index'
LOGOUT_REDIRECT_URL = LOGIN_URL
RAVEN_CONFIG = {
'dsn': env.str('SENTRY_DSN', None),
'release': raven.fetch_git_sha(os.path.abspath(os.pardir)),
}