Specific settings for you local build with Vue - uw-it-aca/myuw GitHub Wiki

Get a python 3 virtual env: "/usr/local/bin/virtualenv3 ."

Create a new project directory: "django-admin.py startproject project ."

Update project/settings.py

INSTALLED_APPS = [ (Add the following) 'webpack_loader', ]

ALLOWED_HOSTS = ['axd3.s.uw.edu'] (or your host)

COMPRESS_ENABLED = False
COMPRESS_OFFLINE = False
COMPRESS_ROOT = "../static/"
STATIC_ROOT = '../static/'
STATIC_URL = '/static/'
MEDIA_ROOT = "../statics/hx_images"
MEDIA_URL = "/uploaded_images/"

ENV = 'localdev'

WEBPACK_LOADER = {
'DEFAULT': {
    'CACHE': not DEBUG,
    'BUNDLE_DIR_NAME': '../static/myuw/', # must end with slash
    'STATS_FILE': os.path.join('../static/', 'myuw-webpack-stats.json'),
    'POLL_INTERVAL': 0.1,
    'TIMEOUT': None,
    'IGNORE': [r'.+\.hot-update.js', r'.+\.map'],
    'LOADER_CLASS': 'webpack_loader.loader.WebpackLoader',
    }
}

Update project/urls.py

from django.urls import include, re_path

urlpatterns = [
    re_path(r'^saml/', include('uw_saml.urls')),
    re_path(r'^support', include('userservice.urls')),
    re_path(r'^logging', include('django_client_logger.urls')),
    re_path(r'^logging', include('rc_django.urls')),
    re_path(r'^', include('myuw.urls')),
]