diff --git a/boofilsic/settings.py b/boofilsic/settings.py index 48c1f9f1..862595c7 100644 --- a/boofilsic/settings.py +++ b/boofilsic/settings.py @@ -1,15 +1,3 @@ -""" -Django settings for boofilsic project. - -Generated by 'django-admin startproject' using Django 3.0.5. - -For more information on this file, see -https://docs.djangoproject.com/en/3.0/topics/settings/ - -For the full list of settings and their values, see -https://docs.djangoproject.com/en/3.0/ref/settings/ -""" - import os PROJECT_ROOT = os.path.abspath(os.path.dirname(__name__)) @@ -38,7 +26,7 @@ INTERNAL_IPS = ["127.0.0.1"] # Application definition INSTALLED_APPS = [ - "maintenance_mode", # this has to be first + # "maintenance_mode", # this has to be first if enabled "django.contrib.admin", "hijack", "hijack.contrib.admin", @@ -60,6 +48,8 @@ INSTALLED_APPS = [ "easy_thumbnails", "user_messages", "fontawesomefree", + # "anymail", + # "silk", ] INSTALLED_APPS += [ @@ -80,6 +70,7 @@ INSTALLED_APPS += [ # we may override templates in these 3rd party apps MIDDLEWARE = [ "django.middleware.security.SecurityMiddleware", + # "silk.middleware.SilkyMiddleware", "django.contrib.sessions.middleware.SessionMiddleware", "django.middleware.common.CommonMiddleware", "django.middleware.csrf.CsrfViewMiddleware", @@ -90,7 +81,7 @@ MIDDLEWARE = [ "hijack.middleware.HijackUserMiddleware", "tz_detect.middleware.TimezoneMiddleware", "auditlog.middleware.AuditlogMiddleware", - "maintenance_mode.middleware.MaintenanceModeMiddleware", # this should be last + # "maintenance_mode.middleware.MaintenanceModeMiddleware", # this should be last if enabled ] ROOT_URLCONF = "boofilsic.urls" @@ -102,7 +93,7 @@ TEMPLATES = [ "APP_DIRS": True, "OPTIONS": { "context_processors": [ - "django.template.context_processors.debug", + # "django.template.context_processors.debug", "django.template.context_processors.request", "django.contrib.auth.context_processors.auth", # 'django.contrib.messages.context_processors.messages', @@ -285,28 +276,17 @@ MASTODON_CLIENT_SCOPE = "read write follow" MASTODON_LEGACY_CLIENT_SCOPE = "read write follow" -# Tags for toots posted from this site -MASTODON_TAGS = "#NiceDB #NiceDB%(category)s #NiceDB%(category)s%(type)s" - # Emoji code in mastodon STAR_SOLID = ":star_solid:" STAR_HALF = ":star_half:" STAR_EMPTY = ":star_empty:" -# Default password for each user. since password is not used any way, -# any string that is not empty is ok -DEFAULT_PASSWORD = "ab7nsm8didusbaqPgq" - # Default redirect loaction when access login required view LOGIN_URL = "/account/login" # Admin site root url ADMIN_URL = "tertqX7256n7ej8nbv5cwvsegdse6w7ne5rHd" -# Luminati proxy settings -LUMINATI_USERNAME = "lum-customer-hl_nw4tbv78-zone-static" -LUMINATI_PASSWORD = "nsb7te9bw0ney" - SCRAPING_TIMEOUT = 90 # ScraperAPI api key @@ -419,11 +399,17 @@ DOWNLOADER_RETRIES = 3 DOWNLOADER_SAVEDIR = None DISABLE_MODEL_SIGNAL = False # disable index and social feeds during importing/etc -MAINTENANCE_MODE = False -MAINTENANCE_MODE_IGNORE_ADMIN_SITE = True -MAINTENANCE_MODE_IGNORE_SUPERUSER = True -MAINTENANCE_MODE_IGNORE_ANONYMOUS_USER = True -MAINTENANCE_MODE_IGNORE_URLS = (r"^/users/connect/", r"^/users/OAuth2_login/") +# MAINTENANCE_MODE = False +# MAINTENANCE_MODE_IGNORE_ADMIN_SITE = True +# MAINTENANCE_MODE_IGNORE_SUPERUSER = True +# MAINTENANCE_MODE_IGNORE_ANONYMOUS_USER = True +# MAINTENANCE_MODE_IGNORE_URLS = (r"^/users/connect/", r"^/users/OAuth2_login/") + +# SILKY_AUTHENTICATION = True # User must login +# SILKY_AUTHORISATION = True # User must have permissions +# SILKY_PERMISSIONS = lambda user: user.is_superuser +# SILKY_MAX_RESPONSE_BODY_SIZE = 1024 # If response body>1024 bytes, ignore +# SILKY_INTERCEPT_PERCENT = 10 DISCORD_WEBHOOKS = {}