1- # Copyright 2023 Google LLC
1+ # Copyright 2024 Google LLC
22#
33# Licensed under the Apache License, Version 2.0 (the "License");
44# you may not use this file except in compliance with the License.
1212# See the License for the specific language governing permissions and
1313# limitations under the License.
1414
15- from ubuntu:22 .04
15+ from ubuntu:24 .04
1616
1717ENV DEBIAN_FRONTEND noninteractive
1818
@@ -40,7 +40,6 @@ RUN apt-get update \
4040 libssl-dev \
4141 libsqlite3-dev \
4242 portaudio19-dev \
43- python3-distutils \
4443 redis-server \
4544 software-properties-common \
4645 ssh \
@@ -60,24 +59,31 @@ RUN apt-get update \
6059 && rm -rf /var/lib/apt/lists/* \
6160 && rm -f /var/cache/apt/archives/*.deb
6261
63- # ##################### Install python 3.9.13
6462
65- # Download python 3.9.13
66- RUN wget https://www.python.org/ftp/python/3.9.13/Python-3.9.13.tgz
63+ # ##################### Install python 3.10.14 for docs/docfx session
64+
65+ # Download python 3.10.14
66+ RUN wget https://www.python.org/ftp/python/3.10.14/Python-3.10.14.tgz
6767
6868# Extract files
69- RUN tar -xvf Python-3.9.13 .tgz
69+ RUN tar -xvf Python-3.10.14 .tgz
7070
71- # Install python 3.9.13
72- RUN ./Python-3.9.13 /configure --enable-optimizations
71+ # Install python 3.10.14
72+ RUN ./Python-3.10.14 /configure --enable-optimizations
7373RUN make altinstall
7474
75+ ENV PATH /usr/local/bin/python3.10:$PATH
76+
7577# ##################### Install pip
7678RUN wget -O /tmp/get-pip.py 'https://bootstrap.pypa.io/get-pip.py' \
77- && python3 /tmp/get-pip.py \
79+ && python3.10 /tmp/get-pip.py \
7880 && rm /tmp/get-pip.py
7981
8082# Test pip
81- RUN python3 -m pip
83+ RUN python3.10 -m pip
84+
85+ # Install build requirements
86+ COPY requirements.txt /requirements.txt
87+ RUN python3.10 -m pip install --require-hashes -r requirements.txt
8288
83- CMD ["python3.8 " ]
89+ CMD ["python3.10 " ]
0 commit comments