Advertisement
Guest User

settings

a guest
Apr 18th, 2018
315
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 3.07 KB | None | 0 0
  1. # settings.py
  2.  
  3. """
  4. Django settings for ProiectTI project.
  5.  
  6. Generated by 'django-admin startproject' using Django 1.11.11.
  7.  
  8. For more information on this file, see
  9. https://docs.djangoproject.com/en/1.11/topics/settings/
  10.  
  11. For the full list of settings and their values, see
  12. https://docs.djangoproject.com/en/1.11/ref/settings/
  13. """
  14.  
  15. import os
  16.  
  17. # Build paths inside the project like this: os.path.join(BASE_DIR, ...)
  18. BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
  19.  
  20.  
  21. # Quick-start development settings - unsuitable for production
  22. # See https://docs.djangoproject.com/en/1.11/howto/deployment/checklist/
  23.  
  24. # SECURITY WARNING: keep the secret key used in production secret!
  25. SECRET_KEY = '#uu6b%wc$$h658g#!@g^zf=5qjq7t4#h7#56pqhwk0&q-q-&a8'
  26.  
  27. # SECURITY WARNING: don't run with debug turned on in production!
  28. DEBUG = True
  29.  
  30. ALLOWED_HOSTS = []
  31.  
  32. # Application definition
  33.  
  34. INSTALLED_APPS = [
  35.     'django.contrib.admin',
  36.     'django.contrib.auth',
  37.     'django.contrib.contenttypes',
  38.     'django.contrib.sessions',
  39.     'django.contrib.messages',
  40.     'django.contrib.staticfiles',
  41.     'my_app',
  42. ]
  43.  
  44. MIDDLEWARE = [
  45.     'django.middleware.security.SecurityMiddleware',
  46.     'django.contrib.sessions.middleware.SessionMiddleware',
  47.     'django.middleware.common.CommonMiddleware',
  48.     'django.middleware.csrf.CsrfViewMiddleware',
  49.     'django.contrib.auth.middleware.AuthenticationMiddleware',
  50.     'django.contrib.messages.middleware.MessageMiddleware',
  51.     'django.middleware.clickjacking.XFrameOptionsMiddleware',
  52. ]
  53.  
  54. ROOT_URLCONF = 'ProiectTI.urls'
  55.  
  56. TEMPLATES = [
  57.     {
  58.         'BACKEND': 'django.template.backends.django.DjangoTemplates',
  59.         'DIRS': [os.path.join(BASE_DIR, 'templates')],
  60.         'APP_DIRS': True,
  61.         'OPTIONS': {
  62.             'context_processors': [
  63.                 'django.template.context_processors.debug',
  64.                 'django.template.context_processors.request',
  65.                 'django.contrib.auth.context_processors.auth',
  66.                 'django.contrib.messages.context_processors.messages',
  67.             ],
  68.         },
  69.     },
  70. ]
  71.  
  72. WSGI_APPLICATION = 'ProiectTI.wsgi.application'
  73.  
  74.  
  75. # Database
  76. # https://docs.djangoproject.com/en/1.11/ref/settings/#databases
  77.  
  78. DATABASES = {
  79.     #Here i deleted the content because i had the user and password from my remote database
  80. }
  81.  
  82.  
  83. # Password validation
  84. # https://docs.djangoproject.com/en/1.11/ref/settings/#auth-password-validators
  85.  
  86. AUTH_PASSWORD_VALIDATORS = [
  87.  
  88. ]
  89.  
  90.  
  91. # Internationalization
  92. # https://docs.djangoproject.com/en/1.11/topics/i18n/
  93.  
  94. LANGUAGE_CODE = 'en-us'
  95.  
  96. TIME_ZONE = 'UTC'
  97.  
  98. USE_I18N = True
  99.  
  100. USE_L10N = True
  101.  
  102. USE_TZ = True
  103.  
  104.  
  105. # Static files (CSS, JavaScript, Images)
  106. # https://docs.djangoproject.com/en/1.11/howto/static-files/
  107.  
  108. STATIC_URL = '/static/'
  109.  
  110. LOGIN_REDIRECT_URL = 'home'
  111. LOGOUT_REDIRECT_URL = 'home'
  112.  
  113. EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend'
  114. EMAIL_HOST = 'localhost'
  115. EMAIL_PORT = 25
  116. EMAIL_HOST_USER = ''
  117. EMAIL_HOST_PASSWORD = ''
  118. EMAIL_USE_TLS = False
  119. DEFAULT_FROM_EMAIL = 'Server <server@whatever.com>'
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement