Added static route to global urls

This commit is contained in:
Claudio Maggioni (maggicl) 2019-04-28 16:31:45 +02:00
parent 4bf2eb6389
commit 540a6b9d14
2 changed files with 7 additions and 4 deletions

View File

@ -15,14 +15,18 @@ Including another URLconf
"""
from django.contrib import admin
from django.urls import path, include
from django.conf import settings
from django.conf.urls.static import static
from django.conf.urls.i18n import i18n_patterns
from django.views.i18n import JavaScriptCatalog
urlpatterns = i18n_patterns(
path('', include('counter.urls')),
path('admin/', admin.site.urls),
path('accounts/', include('user.urls')),
path('accounts/', include('django.contrib.auth.urls')),
path('jsi18n/', JavaScriptCatalog.as_view(), name='javascript-catalog'),
)
urlpatterns += static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)

View File

@ -5,9 +5,8 @@ chdir = %d/
# load Django's wsgi.py for this application
module = arrowcounter.wsgi:application
# serve static files under app static dirs
static-map2 = /static=%d/counter
static-map2 = /static=%d/user
# serve static files under the global static dir
static-map2 = /static=%d
static-expires = /* 7776000
offload-threads = %k