diff options
| author | 2019-07-03 16:46:32 +0200 | |
|---|---|---|
| committer | 2019-07-03 16:46:32 +0200 | |
| commit | 4bbf886a3f99027e3db00b1ca05245712668a502 (patch) | |
| tree | 3f2ca3ad3f3094bd124b53cdafe93b7d4716d09e /pydis_site | |
| parent | Adding whitenoise to the toolchain to serve static images (diff) | |
removing possible hardcoded passwords
Diffstat (limited to 'pydis_site')
| -rw-r--r-- | pydis_site/apps/api/tests/base.py | 2 | ||||
| -rw-r--r-- | pydis_site/settings.py | 19 | 
2 files changed, 4 insertions, 17 deletions
diff --git a/pydis_site/apps/api/tests/base.py b/pydis_site/apps/api/tests/base.py index 37459f70..b779256e 100644 --- a/pydis_site/apps/api/tests/base.py +++ b/pydis_site/apps/api/tests/base.py @@ -5,7 +5,7 @@ from rest_framework.test import APITestCase  test_user, _created = User.objects.get_or_create(      username='test',      email='[email protected]', -    password='testpass',  # noqa: S106 +    password='testpass',  # noqa      is_superuser=True,      is_staff=True  ) diff --git a/pydis_site/settings.py b/pydis_site/settings.py index 06eb9743..d38da34e 100644 --- a/pydis_site/settings.py +++ b/pydis_site/settings.py @@ -20,11 +20,8 @@ env = environ.Env(      DEBUG=(bool, False)  ) -  # Build paths inside the project like this: os.path.join(BASE_DIR, ...)  BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) - -  DEBUG = env('DEBUG')  # Quick-start development settings - unsuitable for production @@ -39,11 +36,11 @@ if DEBUG:          'staff.pythondiscord.local',          'wiki.pythondiscord.local',      ] -    SECRET_KEY = "+_x00w3e94##2-qm-v(5&-x_@*l3t9zlir1etu+7$@4%!it2##" +    SECRET_KEY = "yellow polkadot bikini"  elif 'CI' in os.environ:      ALLOWED_HOSTS = ['*'] -    SECRET_KEY = "{©ø¬½.Þ7&Ñ`Q^Kº*~¢j<wxß¾±ðÛJ@q" +    SECRET_KEY = "yellow polkadot bikini"  else:      ALLOWED_HOSTS = env.list( @@ -137,7 +134,6 @@ TEMPLATES = [  WSGI_APPLICATION = 'pydis_site.wsgi.application' -  # Database  # https://docs.djangoproject.com/en/2.1/ref/settings/#databases @@ -145,7 +141,6 @@ DATABASES = {      'default': env.db()  } -  # Password validation  # https://docs.djangoproject.com/en/2.1/ref/settings/#auth-password-validators @@ -164,21 +159,14 @@ AUTH_PASSWORD_VALIDATORS = [      },  ] -  # Internationalization  # https://docs.djangoproject.com/en/2.1/topics/i18n/ -  LANGUAGE_CODE = 'en-us' -  TIME_ZONE = 'UTC' -  USE_I18N = True -  USE_L10N = True -  USE_TZ = True -  # Static files (CSS, JavaScript, Images)  # https://docs.djangoproject.com/en/2.1/howto/static-files/ @@ -224,7 +212,6 @@ REST_FRAMEWORK = {      'TEST_REQUEST_DEFAULT_FORMAT': 'json'  } -  # Logging  # https://docs.djangoproject.com/en/2.1/topics/logging/  LOGGING = { @@ -291,7 +278,7 @@ BULMA_SETTINGS = {  }  # Required for the wiki -LOGIN_URL = "/admin/login"  # TODO: Update this when the real login system is in place +LOGIN_URL = "/admin/login"  # Update this when the real login system is in place  SITE_ID = 1  WIKI_ACCOUNT_HANDLING = False  |