mirror of
https://github.com/inventree/InvenTree.git
synced 2026-07-05 06:32:55 +00:00
build(docker): compile backend translations during image build (#12203)
* build(docker): compile backend trasnlations during image build * test(docker): verify compiled backend translations exist in image Add checks to the "Test Docker Image" step that assert the compiled django.mo files are present for a few representative languages (de, fr, ru, zh_Hans). This guards the newly added backend translation compilation step in the production Dockerfile, ensuring the multilingual artifacts are produced at the expected locale paths. * test(docker): verify compiled frontend translations exist in image
This commit is contained in:
@@ -145,6 +145,9 @@ ENV PATH=/root/.local/bin:$PATH
|
||||
COPY --from=builder_stage ${INVENTREE_BACKEND_DIR}/InvenTree/web/static/web ${INVENTREE_BACKEND_DIR}/InvenTree/web/static/web
|
||||
COPY --from=builder_stage /root/.local /root/.local
|
||||
|
||||
# Compile Django backend translations during image build
|
||||
RUN bash -c "cd '${INVENTREE_HOME}' && invoke int.backend-compilemessages"
|
||||
|
||||
# Launch the production server
|
||||
CMD ["sh", "-c", "exec gunicorn -c ./gunicorn.conf.py InvenTree.wsgi -b ${INVENTREE_WEB_ADDR}:${INVENTREE_WEB_PORT} --chdir ${INVENTREE_BACKEND_DIR}/InvenTree"]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user