Skip to content

Commit ed456b1

Browse files
committed
fix: Don't build uwsgi with xml support.
When uwsgi runs with xml support, it throws the following error on startup with the latest version of edx-platform: ``` xmlsec.InternalError: (-1, 'lxml & xmlsec libxml2 library version mismatch') ``` See xmlsec/python-xmlsec#320 for more details on this. Essentially, the uWSGI wheel is built against a different version of libxml2 and it causes this version mismach error when trying to load xmlsec. The xml support in uWSGI is only needed for runing with xml configuration files, which tutor does not do. Following the guidance of the above issue, I updated the `openedx` Dockerfile to no longer compile with any xml support as a part of the build. The time to build uWSGI was only slightly more than building from cache so I'm not concerned about major slowdowns in the build time for un-cached builds.
1 parent d4e6c6c commit ed456b1

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tutor/templates/build/openedx/Dockerfile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,8 +98,10 @@ RUN --mount=type=bind,from=edx-platform,source=/requirements/edx/base.txt,target
9898
pip install -r /openedx/edx-platform/requirements/edx/base.txt
9999

100100
# Install extra requirements
101+
# We don't need xml configuration support in uwsgi so don't install it.
101102
RUN --mount=type=cache,target=/openedx/.cache/pip,sharing=shared \
102-
pip install \
103+
UWSGI_PROFILE_OVERRIDE="xml=no" \
104+
pip install --no-cache-dir --compile \
103105
# Use redis as a django cache https://pypi.org/project/django-redis/
104106
django-redis==5.4.0 \
105107
# uwsgi server https://pypi.org/project/uWSGI/

0 commit comments

Comments
 (0)