mirror of
https://github.com/YunoHost-Apps/django_example_ynh.git
synced 2024-09-03 18:26:21 +02:00
fix serve static files
This commit is contained in:
parent
3d8b18788e
commit
a58ba43e18
2 changed files with 1 additions and 5 deletions
|
@ -1,5 +1,4 @@
|
|||
from django.conf import settings
|
||||
from django.conf.urls import static
|
||||
from django.contrib import admin
|
||||
from django.urls import path
|
||||
|
||||
|
@ -12,6 +11,3 @@ urlpatterns = [
|
|||
path(f'{settings.PATH_URL}/', admin.site.urls),
|
||||
path(f'{settings.PATH_URL}/debug/', request_media_debug_view),
|
||||
]
|
||||
|
||||
if settings.SERVE_FILES:
|
||||
urlpatterns += static.static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)
|
||||
|
|
|
@ -119,7 +119,7 @@ def create_local_test(django_settings_path, destination, runserver=False):
|
|||
os.environ['HTTP_AUTHORIZATION'] = generate_basic_auth(username='test', password='test123')
|
||||
|
||||
try:
|
||||
call_manage_py(final_home_path, 'runserver --nostatic')
|
||||
call_manage_py(final_home_path, 'runserver')
|
||||
except KeyboardInterrupt:
|
||||
print('\nBye ;)')
|
||||
|
||||
|
|
Loading…
Reference in a new issue