/
githubmirror
/
oppia
Обзор
Документация
Войти
/
githubmirror
/
oppia
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
v3.4.7
docker/Dockerfile.backend
61 строка
2 KB
Nikhil
Fixes part of #21214: Upgrades Python version from 3.9 to 3.10 (#22536)
11 июл 2025, 13:46
Не верифицирован
11 июл 2025, 13:46
ed02a37
Код
Авторство
О чём код?
# The platform flag is added because of https://stackoverflow.com/a/71611002 FROM --platform=linux/amd64 python:3.10.16-slim-bullseye AS backend ENV OPPIA_IS_DOCKERIZED="true" WORKDIR / # Installing prerequisite libs and dependencies. RUN apt-get update -y && apt-get upgrade -y \ curl \ git \ npm \ openjdk-11-jre \ unzip \ wget \ jq RUN curl -sL https://deb.nodesource.com/setup_16.x | bash - RUN apt-get install -y nodejs RUN curl -L -o google-chrome.deb https://github.com/webnicer/chrome-downloads/raw/master/x64.deb/google-chrome-stable_117.0.5938.149-1_amd64.deb RUN apt-get install -y ./google-chrome.deb RUN rm google-chrome.deb RUN pip install --upgrade pip==21.2.3 RUN pip install pip-tools==6.6.2 setuptools==58.5.3 cmake WORKDIR /app/vm_deps # Installing Google Cloud SDK RUN wget -O /app/vm_deps/gcloud-sdk.tar.gz https://dl.google.com/dl/cloudsdk/channels/rapid/downloads/google-cloud-sdk-500.0.0-linux-x86_64.tar.gz && \ tar -xzf gcloud-sdk.tar.gz && \ ./google-cloud-sdk/install.sh --quiet && \ ./google-cloud-sdk/bin/gcloud components install beta cloud-datastore-emulator app-engine-python app-engine-python-extras && \ rm gcloud-sdk.tar.gz # Install DSAdmin WORKDIR /app RUN curl -L https://github.com/remko/dsadmin/releases/download/v0.20.0/dsadmin-v0.20.0-linux-amd64.tar.gz | tar -xzvf - WORKDIR /app/oppia RUN npm install typescript@4.1.6 # Installing python dependencies from the requirements_dev.txt file COPY requirements.txt . COPY requirements_dev.txt . RUN pip install --require-hashes --no-deps -r requirements.txt -t /app/oppia/third_party/python_libs RUN pip install --require-hashes --no-deps -r requirements_dev.txt RUN pip download --no-deps -r requirements.txt -d /root/.cache RUN pip download --no-deps -r requirements_dev.txt -d /root/.cache # Installing third party dependencies COPY scripts/install_dependencies_json_packages.py ./scripts/install_dependencies_json_packages.py COPY dependencies.json . # This script downloads frontend dependencies, which should be removed once the dependencies.json file is deprecated. RUN python -m scripts.install_dependencies_json_packages # Mark /app/oppia as a safe directory for Git operations to work properly in tests. RUN git config --global --add safe.directory /app/oppia