Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/nightly' into kdmccormick/assets
Browse files Browse the repository at this point in the history
  • Loading branch information
kdmccormick committed May 20, 2024
2 parents 5f79206 + c84a741 commit aba2af3
Showing 1 changed file with 19 additions and 2 deletions.
21 changes: 19 additions & 2 deletions tutor/templates/build/openedx/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -377,15 +377,32 @@ RUN ./manage.py cms collectstatic --noinput --settings=tutor.assets
# De-dupe static assets with synlinks
RUN rdfind -makesymlinks true -followsymlinks true /openedx/staticfiles/

# Default amount of uWSGI processes
ENV UWSGI_WORKERS=2
# Build & collect production assets. By default, only assets from the default theme
# will be processed. This makes the docker image lighter and faster to build.
RUN npm run postinstall # Postinstall artifacts are stuck in nodejs-requirements layer. Create them here too.
RUN npm run compile-sass -- --skip-themes
RUN npm run webpack

# Now that the default theme is built, build any custom themes
COPY --chown=app:app ./themes/ /openedx/themes
RUN npm run compile-sass -- --skip-default

# and finally, collect assets for the production image,
# de-duping assets with symlinks.
RUN ./manage.py lms collectstatic --noinput --settings=tutor.assets && \
./manage.py cms collectstatic --noinput --settings=tutor.assets && \
# De-duplicate static assets with symlinks \
rdfind -makesymlinks true -followsymlinks true /openedx/staticfiles/

# Copy the default uWSGI configuration
COPY --chown=app:app settings/uwsgi.ini .

# Default django settings
ENV DJANGO_SETTINGS_MODULE lms.envs.tutor.production

# Default amount of uWSGI processes
ENV UWSGI_WORKERS=2

# Run server
CMD uwsgi uwsgi.ini

Expand Down

0 comments on commit aba2af3

Please sign in to comment.