From 979bea17ed96c101e55a4224e3c72f605233c4af Mon Sep 17 00:00:00 2001 From: "Langhammer, Jens" Date: Wed, 20 Nov 2019 13:12:37 +0100 Subject: [PATCH] root(minor): disable error reporting by default --- helm/passbook/templates/configmap.yaml | 2 +- helm/passbook/values.yaml | 2 +- passbook/lib/default.yml | 4 ++-- passbook/root/settings.py | 4 +++- 4 files changed, 7 insertions(+), 5 deletions(-) diff --git a/helm/passbook/templates/configmap.yaml b/helm/passbook/templates/configmap.yaml index 9a3b8c16c..d4084b1fe 100644 --- a/helm/passbook/templates/configmap.yaml +++ b/helm/passbook/templates/configmap.yaml @@ -12,5 +12,5 @@ data: host: "{{ .Release.Name }}-redis-master" cache_db: 0 message_queue_db: 1 - error_report_enabled: {{ .Values.config.error_reporting }} + error_reporting: {{ .Values.config.error_reporting }} domain: ".{{ index .Values.ingress.hosts 0 }}" diff --git a/helm/passbook/values.yaml b/helm/passbook/values.yaml index 549ec9aa9..059fa2d55 100644 --- a/helm/passbook/values.yaml +++ b/helm/passbook/values.yaml @@ -10,7 +10,7 @@ config: # Optionally specify fixed secret_key, otherwise generated automatically # secret_key: _k*@6h2u2@q-dku57hhgzb7tnx*ba9wodcb^s9g0j59@=y(@_o # Enable error reporting - error_reporting: true + error_reporting: false email: host: localhost diff --git a/passbook/lib/default.yml b/passbook/lib/default.yml index 57ef14365..35ce3aa63 100644 --- a/passbook/lib/default.yml +++ b/passbook/lib/default.yml @@ -13,8 +13,8 @@ redis: debug: false -# Error reporting, sends stacktrace to sentry.services.beryju.org -error_report_enabled: true +# Error reporting, sends stacktrace to sentry.beryju.org +error_reporting: false domain: localhost diff --git a/passbook/root/settings.py b/passbook/root/settings.py index 07dda222a..ecd2c9fa5 100644 --- a/passbook/root/settings.py +++ b/passbook/root/settings.py @@ -266,7 +266,9 @@ if CONFIG.y('postgresql.backup'): } # Sentry integration -if not DEBUG: +_ERROR_REPORTING = CONFIG.y_bool('error_reporting', False) +if not DEBUG and _ERROR_REPORTING: + LOGGER.info("Error reporting is enabled.") sentry_init( dsn="https://33cdbcb23f8b436dbe0ee06847410b67@sentry.beryju.org/3", integrations=[