diff --git a/cms/settings/dev.py b/cms/settings/dev.py index 45efd866..87d05eb2 100644 --- a/cms/settings/dev.py +++ b/cms/settings/dev.py @@ -14,19 +14,15 @@ # Allow requests from the local IPs to see more debug information. INTERNAL_IPS = ("127.0.0.1", "10.0.2.2") - # This is only to test Wagtail emails. WAGTAILADMIN_BASE_URL = "http://localhost:8000" - # Display sent emails in the console while developing locally. EMAIL_BACKEND = "django.core.mail.backends.console.EmailBackend" - # Disable password validators when developing locally. AUTH_PASSWORD_VALIDATORS = [] - # Enable Wagtail's style guide in Wagtail's settings menu. # http://docs.wagtail.io/en/stable/contributing/styleguide.html INSTALLED_APPS += ["wagtail.contrib.styleguide"] # noqa: F405 @@ -37,7 +33,6 @@ # For the same reason the HSTS header should not be sent. SECURE_HSTS_SECONDS = 0 - # Adds Django Debug Toolbar INSTALLED_APPS.append("debug_toolbar") MIDDLEWARE.insert(0, "debug_toolbar.middleware.DebugToolbarMiddleware") # noqa: F405 @@ -57,7 +52,12 @@ DATABASES["read_replica"] = copy.deepcopy(DATABASES["default"]) # Redis -REDIS_URL = "redis://localhost:6379" +REDIS_URL = env.get("REDIS_URL", "redis://localhost:6379") # noqa: F405 +CACHES["default"] = { # noqa: F405 + "BACKEND": "django_redis.cache.RedisCache", + "LOCATION": REDIS_URL, + "OPTIONS": {**redis_options}, # noqa: F405 +} # Django Defender ENABLE_DJANGO_DEFENDER = False