diff --git a/CHANGELOG.md b/CHANGELOG.md index 589b233..4850cb1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,7 @@ Note: Breaking changes between versions are indicated by "💥". ## Unreleased +- [Bugfix] Fix missing js translations - [Bugfix] Fix tls certificate generation in cron jobs ## v3.11.6 (2020-03-13) diff --git a/tutor/templates/build/openedx/Dockerfile b/tutor/templates/build/openedx/Dockerfile index 21cbf5d..81039b9 100644 --- a/tutor/templates/build/openedx/Dockerfile +++ b/tutor/templates/build/openedx/Dockerfile @@ -75,6 +75,12 @@ ENV CONFIG_ROOT /openedx/config COPY settings/lms/*.py ./lms/envs/tutor/ COPY settings/cms/*.py ./cms/envs/tutor/ +# Compile i18n strings: in Ironwood, js locales are not properly compiled out of the box +# and we need to do a pass ourselves. Also, we need to compile the djangojs.js files for +# the downloaded locales. +RUN ./manage.py lms --settings=tutor.i18n compilejsi18n +RUN ./manage.py cms --settings=tutor.i18n compilejsi18n + # Copy scripts COPY ./bin /openedx/bin RUN chmod a+x /openedx/bin/* diff --git a/tutor/templates/build/openedx/settings/cms/assets.py b/tutor/templates/build/openedx/settings/cms/assets.py index 914453d..4acdef6 100644 --- a/tutor/templates/build/openedx/settings/cms/assets.py +++ b/tutor/templates/build/openedx/settings/cms/assets.py @@ -4,3 +4,5 @@ STATIC_ROOT = path(STATIC_ROOT_BASE) / 'studio' WEBPACK_LOADER['DEFAULT']['STATS_FILE'] = STATIC_ROOT / "webpack-stats.json" derive_settings(__name__) + +LOCALE_PATHS.append("/openedx/locale") diff --git a/tutor/templates/build/openedx/settings/cms/i18n.py b/tutor/templates/build/openedx/settings/cms/i18n.py new file mode 100644 index 0000000..46cb6af --- /dev/null +++ b/tutor/templates/build/openedx/settings/cms/i18n.py @@ -0,0 +1 @@ +{% include "build/openedx/settings/partials/i18n.py" %} diff --git a/tutor/templates/build/openedx/settings/lms/assets.py b/tutor/templates/build/openedx/settings/lms/assets.py index b3f85de..d286363 100644 --- a/tutor/templates/build/openedx/settings/lms/assets.py +++ b/tutor/templates/build/openedx/settings/lms/assets.py @@ -4,3 +4,5 @@ STATIC_ROOT = path(STATIC_ROOT_BASE) WEBPACK_LOADER['DEFAULT']['STATS_FILE'] = STATIC_ROOT / "webpack-stats.json" derive_settings(__name__) + +LOCALE_PATHS.append("/openedx/locale") diff --git a/tutor/templates/build/openedx/settings/lms/i18n.py b/tutor/templates/build/openedx/settings/lms/i18n.py new file mode 100644 index 0000000..46cb6af --- /dev/null +++ b/tutor/templates/build/openedx/settings/lms/i18n.py @@ -0,0 +1 @@ +{% include "build/openedx/settings/partials/i18n.py" %} diff --git a/tutor/templates/build/openedx/settings/partials/i18n.py b/tutor/templates/build/openedx/settings/partials/i18n.py new file mode 100644 index 0000000..7a418d9 --- /dev/null +++ b/tutor/templates/build/openedx/settings/partials/i18n.py @@ -0,0 +1,17 @@ +from ..common import * +from openedx.core.lib.derived import derive_settings + +STATIC_ROOT_BASE = '/openedx/staticfiles' + +SECRET_KEY = 'secret' +XQUEUE_INTERFACE = { + 'django_auth': None, + 'url': None, +} +DATABASES = { + "default": {}, +} + +derive_settings(__name__) + +LOCALE_PATHS.append("/openedx/locale") \ No newline at end of file