From 3234a71cde753ca623461073613843342b7384d4 Mon Sep 17 00:00:00 2001 From: Anatoly Date: Wed, 2 Oct 2019 10:34:17 +0300 Subject: [PATCH] gm-148: modified settings, added missing migration --- .../migrations/0003_auto_20191002_0729.py | 17 +++++++++++++++++ project/settings/base.py | 2 ++ project/settings/local.py | 8 +++++++- 3 files changed, 26 insertions(+), 1 deletion(-) create mode 100644 apps/timetable/migrations/0003_auto_20191002_0729.py diff --git a/apps/timetable/migrations/0003_auto_20191002_0729.py b/apps/timetable/migrations/0003_auto_20191002_0729.py new file mode 100644 index 00000000..16196f74 --- /dev/null +++ b/apps/timetable/migrations/0003_auto_20191002_0729.py @@ -0,0 +1,17 @@ +# Generated by Django 2.2.4 on 2019-10-02 07:29 + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('timetable', '0002_auto_20190919_1124'), + ] + + operations = [ + migrations.AlterModelOptions( + name='timetable', + options={'ordering': ['weekday'], 'verbose_name': 'Timetable', 'verbose_name_plural': 'Timetables'}, + ), + ] diff --git a/project/settings/base.py b/project/settings/base.py index 2916cff0..827b78c6 100644 --- a/project/settings/base.py +++ b/project/settings/base.py @@ -453,4 +453,6 @@ STATICFILES_DIRS = ( os.path.join(PROJECT_ROOT, 'static'), ) + +# MEDIA MEDIA_LOCATION = 'media' diff --git a/project/settings/local.py b/project/settings/local.py index f67b8f7e..d842894c 100644 --- a/project/settings/local.py +++ b/project/settings/local.py @@ -4,22 +4,28 @@ import sys ALLOWED_HOSTS = ['*', ] + SEND_SMS = False SMS_CODE_SHOW = True USE_CELERY = False + SCHEMA_URI = 'http' DEFAULT_SUBDOMAIN = 'www' SITE_DOMAIN_URI = 'testserver.com:8000' DOMAIN_URI = '0.0.0.0:8000' + # CELERY BROKER_URL = 'amqp://rabbitmq:5672' CELERY_RESULT_BACKEND = BROKER_URL CELERY_BROKER_URL = BROKER_URL -MEDIA_ROOT = os.path.join(PUBLIC_ROOT, MEDIA_LOCATION) + +# MEDIA MEDIA_URL = f'{SCHEMA_URI}://{DOMAIN_URI}/{MEDIA_LOCATION}/' +MEDIA_ROOT = os.path.join(PUBLIC_ROOT, MEDIA_LOCATION) + # LOGGING LOGGING = {