2Django settings for mp_integration project.
4Generated by 'django-admin startproject' using Django 5.2.1.
6For more information on this file, see
7https://docs.djangoproject.com/en/5.2/topics/settings/
9For the full list of settings and their values, see
10https://docs.djangoproject.com/en/5.2/ref/settings/
14from pathlib
import Path
15from dotenv
import load_dotenv
18BASE_DIR = Path(__file__).resolve().parent.parent
21load_dotenv(os.path.join(BASE_DIR,
'.env'))
24SECRET_KEY = os.getenv(
'DJANGO_SECRET_KEY',
'django-insecure-your-secret-key-for-development')
27DEBUG = os.getenv(
'DJANGO_DEBUG',
'True') ==
'True'
29ALLOWED_HOSTS = os.getenv(
'DJANGO_ALLOWED_HOSTS',
'*').split(
',')
33 'django.contrib.admin',
34 'django.contrib.auth',
35 'django.contrib.contenttypes',
36 'django.contrib.sessions',
37 'django.contrib.messages',
38 'django.contrib.staticfiles',
45 'django.middleware.security.SecurityMiddleware',
46 'django.contrib.sessions.middleware.SessionMiddleware',
47 'corsheaders.middleware.CorsMiddleware',
48 'django.middleware.common.CommonMiddleware',
49 'django.middleware.csrf.CsrfViewMiddleware',
50 'django.contrib.auth.middleware.AuthenticationMiddleware',
51 'django.contrib.messages.middleware.MessageMiddleware',
52 'django.middleware.clickjacking.XFrameOptionsMiddleware',
55ROOT_URLCONF =
'mp_integration.urls'
59 'BACKEND':
'django.template.backends.django.DjangoTemplates',
63 'context_processors': [
64 'django.template.context_processors.debug',
65 'django.template.context_processors.request',
66 'django.contrib.auth.context_processors.auth',
67 'django.contrib.messages.context_processors.messages',
73WSGI_APPLICATION =
'mp_integration.wsgi.application'
78 'ENGINE':
'django.db.backends.mysql',
81 'PASSWORD':
'BGVqserZKnEpylRlbhwyQcgSmmoocqAt',
82 'HOST':
'shortline.proxy.rlwy.net',
85 'sql_mode':
'traditional',
91AUTH_PASSWORD_VALIDATORS = [
93 'NAME':
'django.contrib.auth.password_validation.UserAttributeSimilarityValidator',
96 'NAME':
'django.contrib.auth.password_validation.MinimumLengthValidator',
99 'NAME':
'django.contrib.auth.password_validation.CommonPasswordValidator',
102 'NAME':
'django.contrib.auth.password_validation.NumericPasswordValidator',
107LANGUAGE_CODE =
'en-us'
113STATIC_URL =
'static/'
116DEFAULT_AUTO_FIELD =
'django.db.models.BigAutoField'
119MERCADOPAGO_ACCESS_TOKEN = os.getenv(
'MERCADOPAGO_ACCESS_TOKEN',
'APP_USR-1638397842548868-051022-6da127c22d6d3b0e023d8ae29f3618c2-2435347984')
122MAIN_BACKEND_URL = os.getenv(
'MAIN_BACKEND_URL',
'https://backmobile1.onrender.com')
125CORS_ALLOW_ALL_ORIGINS =
True
126CORS_ALLOW_CREDENTIALS =
True
127CORS_ALLOW_METHODS = [
135CORS_ALLOW_HEADERS = [