Подправил докерфайл сборки контейнера
All checks were successful
Deploy MES Core / deploy (push) Successful in 2m19s
All checks were successful
Deploy MES Core / deploy (push) Successful in 2m19s
This commit is contained in:
@@ -179,4 +179,7 @@ SECURE_PROXY_SSL_HEADER = ('HTTP_X_FORWARDED_PROTO', 'https')
|
||||
|
||||
CSRF_TRUSTED_ORIGINS = env.list('CSRF_ORIGINS', default=['http://localhost'])
|
||||
|
||||
print(f"--- РАБОТАЕМ НА БАЗЕ: {DATABASES['default']['NAME']} (HOST: {DATABASES['default'].get('HOST', 'localhost')}) ---")
|
||||
print(f"--- РАБОТАЕМ НА БАЗЕ: {DATABASES['default']['NAME']} (HOST: {DATABASES['default'].get('HOST', 'localhost')}) ---")
|
||||
|
||||
print (env)
|
||||
|
||||
|
||||
@@ -16,7 +16,14 @@ Including another URLconf
|
||||
"""
|
||||
from django.contrib import admin
|
||||
from django.urls import path
|
||||
from django.conf.urls.static import static # <--- Добавьте эту строку
|
||||
from core import settings
|
||||
|
||||
urlpatterns = [
|
||||
path('admin/', admin.site.urls),
|
||||
]
|
||||
|
||||
# Вместо if settings.DEBUG: не забываем from django.conf.urls.static import static # <--- Добавьте эту строку
|
||||
if settings.ENV_TYPE in ['local', 'dev']:
|
||||
urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
|
||||
urlpatterns += static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)
|
||||
Reference in New Issue
Block a user