-
Notifications
You must be signed in to change notification settings - Fork 102
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update Dockerfile & CI workflows to use Ubuntu 24.04 and Python 3.12 #397
Merged
Merged
Changes from 3 commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,7 +8,7 @@ on: | |
jobs: | ||
|
||
push: | ||
runs-on: ubuntu-20.04 | ||
runs-on: ubuntu-24.04 | ||
|
||
steps: | ||
- name: Checkout | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,33 +1,33 @@ | ||
FROM edxops/focal-common:latest | ||
FROM ubuntu:noble | ||
|
||
RUN apt-get update && apt-get install -y \ | ||
gettext \ | ||
lib32z1-dev \ | ||
zlib1g-dev \ | ||
libjpeg62-dev \ | ||
libxslt1-dev \ | ||
zlib1g-dev \ | ||
python3 \ | ||
python3-dev \ | ||
python3-venv \ | ||
python3-pip && \ | ||
pip3 install --upgrade pip setuptools && \ | ||
rm -rf /var/lib/apt/lists/* | ||
python3.12 \ | ||
python3.12-dev \ | ||
python3.12-venv \ | ||
curl \ | ||
make \ | ||
&& apt-get clean \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
|
||
COPY . /usr/local/src/xblock-sdk | ||
WORKDIR /usr/local/src/xblock-sdk | ||
|
||
ENV VIRTUAL_ENV=/venvs/xblock-sdk | ||
RUN python3.11 -m venv $VIRTUAL_ENV | ||
RUN python3.12 -m venv $VIRTUAL_ENV | ||
ENV PATH="$VIRTUAL_ENV/bin:$PATH" | ||
|
||
RUN pip install --upgrade pip && pip install -r /usr/local/src/xblock-sdk/requirements/dev.txt | ||
|
||
RUN curl -sL https://deb.nodesource.com/setup_14.x -o /tmp/nodejs-setup && \ | ||
/bin/bash /tmp/nodejs-setup && \ | ||
RUN curl -sL https://deb.nodesource.com/setup_22.x -o /tmp/nodejs-setup && \ | ||
bash /tmp/nodejs-setup && \ | ||
rm /tmp/nodejs-setup && \ | ||
apt-get -y install nodejs && \ | ||
echo $PYTHONPATH && \ | ||
make install | ||
apt-get install -y nodejs | ||
|
||
RUN pip install --upgrade pip setuptools | ||
RUN make install | ||
|
||
EXPOSE 8000 | ||
ENTRYPOINT ["python", "manage.py"] | ||
CMD ["runserver", "0.0.0.0:8000"] | ||
|
||
ENTRYPOINT ["bash", "-c", "python manage.py migrate && exec python manage.py runserver 0.0.0.0:8000"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,3 @@ | ||
version: '3.5' | ||
services: | ||
xblock_sdk: | ||
image: openedx/xblock-sdk | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,4 +10,3 @@ | |
|
||
# Common constraints for edx repos | ||
-c common_constraints.txt | ||
backports.zoneinfo;python_version<"3.9" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
# XBlock Static Files | ||
|
||
An XBlock can load resources from its package using Python's | ||
[pkg_resources](http://pythonhosted.org/distribute/pkg_resources.html). | ||
[importlib.resources](https://docs.python.org/3/library/importlib.resources.html). | ||
|
||
We use a directory structure with folders for `css`, `html`, and `js` | ||
files. However, this structure is not mandatory. Each XBlock can | ||
choose its directory structure, as long as it specifies the correct | ||
paths to `pkg_resources`. | ||
paths to `importlib.resources`. | ||
|
||
We include unit tests for JavaScript in the `js` folder. See `js/README.md` | ||
for details on how to run these tests. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
# XBlock Static Files | ||
|
||
An XBlock can load resources from its package using Python's | ||
[pkg_resources](http://pythonhosted.org/distribute/pkg_resources.html). | ||
[importlib.resources](https://docs.python.org/3/library/importlib.resources.html). | ||
|
||
We use a directory structure with folders for `css`, `html`, and `js` | ||
files. However, this structure is not mandatory. Each XBlock can | ||
choose its directory structure, as long as it specifies the correct | ||
paths to `pkg_resources`. | ||
paths to `importlib.resources`. | ||
|
||
We include unit tests for JavaScript in the `js` folder. See `js/README.md` | ||
for details on how to run these tests. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
# pylint: disable=django-not-configured | ||
""" | ||
Provide a djangoapp for XBlock development | ||
""" | ||
|
||
__version__ = '0.12.0' | ||
__version__ = '0.13.0' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Following sounds concise to me: