text: """Production settings."""
  
  from .base import *  # NOQA
  from .base import env
  import sentry_sdk
  from sentry_sdk.integrations.django import DjangoIntegration
  
  
  # Base
  SECRET_KEY = env("DJANGO_SECRET_KEY")
  ALLOWED_HOSTS = env.list("DJANGO_ALLOWED_HOSTS", default=["*"])
  
  
  # Cache
  CACHES = {
      "default": {
          "BACKEND": "django_redis.cache.RedisCache",
          "LOCATION": env("REDIS_URL"),
          "OPTIONS": {
              "CLIENT_CLASS": "django_redis.client.DefaultClient",
              "IGNORE_EXCEPTIONS": True,
          },
      }
  }
  
  # Templates
  TEMPLATES[0]["OPTIONS"]["loaders"] = [  # noqa F405
      (
          "django.template.loaders.cached.Loader",
          [
              "django.template.loaders.filesystem.Loader",
              "django.template.loaders.app_directories.Loader",
          ],
      )
  ]
  
  # Admin
  ADMIN_URL = env("DJANGO_ADMIN_URL")
  
  # Gunicorn
  INSTALLED_APPS += ["gunicorn"]  # noqa F405
  
  # WhiteNoise
  MIDDLEWARE.insert(1, "whitenoise.middleware.WhiteNoiseMiddleware")  # noqa F405
  
  
  # Logging
  # A sample logging configuration. The only tangible logging
  # performed by this configuration is to send an email to
  # the site admins on every HTTP 500 error when DEBUG=False.
  # See https://docs.djangoproject.com/en/dev/topics/logging for
  # more details on how to customize your logging configuration.
  LOGGING = {
      "version": 1,
      "disable_existing_loggers": False,
      "filters": {
          "require_debug_false": {"()": "django.utils.log.RequireDebugFalse"}
      },
      "formatters": {
          "verbose": {
              "format": "%(levelname)s %(asctime)s %(module)s "
              "%(process)d %(thread)d %(message)s"
          }
      },
      "handlers": {
          "mail_admins": {
              "level": "ERROR",
              "filters": ["require_debug_false"],
              "class": "django.utils.log.AdminEmailHandler",
          },
          "console": {
              "level": "DEBUG",
              "class": "logging.StreamHandler",
              "formatter": "verbose",
          },
      },
      "loggers": {
          "django.request": {
              "handlers": ["mail_admins"],
              "level": "ERROR",
              "propagate": True,
          },
          "django.security.DisallowedHost": {
              "level": "ERROR",
              "handlers": ["console", "mail_admins"],
              "propagate": True,
          },
      },
  }
  