# Generated using bugsink-create-conf --template=local
#
# This is the default configuration when running Bugsink for local development. (i.e. using Bugsink to support the
# software development of other programs on your local machine, _not_ to develop Bugsink itself locally).
#
# SECURITY WARNING: this file should not be used in production; for production, use a configuration file generated by
# bugsink-create-conf --template=default

from bugsink.settings.default import *  # noqa

SECRET_KEY = "{{ secret_key }}"


# Configure the paths to the database. If you do not set these, the databases will be created in the current directory.

# DATABASES["default"]["NAME"] = 'db.sqlite3'
# DATABASES["default"]["TEST"]["NAME"] = 'test.sqlite3'
# DATABASES["snappea"]["NAME"] = 'snappea.sqlite3'


# The time-zone here is the default for display purposes (when no project/user configuration is used).
# You can change this at any time since datetime information is stored as UTC in the database.
# https://docs.djangoproject.com/en/4.2/ref/settings/#std-setting-TIME_ZONE
TIME_ZONE = 'UTC'  # alternatively, e.g. 'Europe/Amsterdam'


# When running locally, it is recommended to configure SNAPPEA to always run eagerly, i.e. to run tasks synchronously.
# This avoids the need to run a separate "snappea server" process to run the workers, and the performance impact is
# negligible for local development.
SNAPPEA = {
    "TASK_ALWAYS_EAGER": True,
}


# When running locally, it is recommended to configure the email backend to use the (quiet) console backend, which
# prints the email to the console instead of sending it. The assumption is basically that you don't want to send emails
# to yourself while developing locally, because the errors that you do trigger will already obvious.
# 
EMAIL_BACKEND = "bugsink.email_backends.QuietConsoleEmailBackend"
# EMAIL_HOST = ...
# EMAIL_HOST_USER = ...
# EMAIL_HOST_PASSWORD = ...
# EMAIL_PORT = ...
# EMAIL_USE_TLS = ...
# SERVER_EMAIL = DEFAULT_FROM_EMAIL = "Bugsink <bugsink@example.org>"

BUGSINK = {
    # The URL where the Bugsink instance is hosted. This is used in the email notifications and to construct DSNs.
    "BASE_URL": "http://{{ host }}:{{ port }}",  # no trailing slash

    # you can customize this as e.g. "My Bugsink" or "Bugsink for My Company"
    # "SITE_TITLE": "Bugsink",  

    # When running locally, it is recommended to configure the Bugsink to digest events immediately. (This is basically
    # implied by the "TASK_ALWAYS_EAGER" setting above, but setting DIGEST_IMMEDIATELY to True removes one more step
    # from the process.)
    "DIGEST_IMMEDIATELY": True,

    # You are licenced to run Bugsink locally in single-user mode. By changing the settings below, you may open the door
    # to more uses; MAKE SURE THAT YOU ARE ALLOWED TO DO SO.
    "SINGLE_USER": True,
    "SINGLE_TEAM": True,
}
