@@ -80,7 +80,7 @@ RUN apt-get update && apt-get upgrade -y && dpkg --configure -a && \
80
80
apt-get clean -y && \
81
81
apt-get install -y \
82
82
gnupg \
83
- ssl-cert \
83
+ ssl-cert \
84
84
libevent-dev \
85
85
libsqlite3-dev \
86
86
libxml2-dev \
@@ -111,21 +111,22 @@ RUN apt-get update && apt-get upgrade -y && dpkg --configure -a && \
111
111
ssh \
112
112
jq \
113
113
htop \
114
- libglx-mesa0 libegl1 libxrandr2 libxrandr2 libxss1 \
114
+ libglx-mesa0 libegl1 libxrandr2 libxss1 \
115
115
libxcursor1 libxcomposite1 libasound2-dev libxi6 libxtst6 \
116
116
r-base \
117
117
libopenblas-dev
118
118
119
119
# remove newer python version, freeze other versions for max compatibility before updates
120
- RUN apt --fix-missing purge $(dpkg -l | grep 'python3\.1[01]' | awk '{print $2}')
120
+ # RUN apt --fix-missing purge $(dpkg -l | grep 'python3\.1[01]' | awk '{print $2}')
121
+
122
+
121
123
RUN apt --fix-broken install
122
124
RUN apt-get purge --auto-remove python3.10
123
125
124
- # python 3.11
125
- RUN apt-get install -y python3.11-full python3.11-dev python3-pip python3-venv
126
-
127
- # be careful, this conflicts
128
- RUN update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.11 1
126
+ # Install Python 3.11 system-wide
127
+ RUN apt-get update && apt-get install -y python3.11-full python3.11-dev python3.11-venv python3-pip \
128
+ && update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.11 2 \
129
+ && update-alternatives --install /usr/bin/pip pip /usr/bin/pip3 2
129
130
130
131
# install remaining packages
131
132
RUN apt-get update && apt-get upgrade -y
@@ -142,6 +143,12 @@ RUN apt-get clean autoclean && apt-get autoremove --purge -y
142
143
143
144
######################################## Python / PIP SECTION ########################################
144
145
RUN conda update conda
146
+
147
+ # Create a Python 3.11 env and make it the default for builds & kernels
148
+ RUN conda create -y -n py311 python=3.11 ipykernel && conda clean --all -f -y
149
+ ENV CONDA_DEFAULT_ENV=py311
150
+ ENV PATH=/opt/conda/envs/py311/bin:$PATH
151
+
145
152
RUN conda install --quiet --yes \
146
153
ipykernel \
147
154
pip \
@@ -155,7 +162,7 @@ RUN conda clean --all -f -y
155
162
RUN fix-permissions $CONDA_DIR && fix-permissions /home/$NB_USER
156
163
157
164
# update pip and install basic utilities
158
- RUN pip3 install --no-cache-dir --upgrade pip wheel
165
+ RUN pip3 install --no-cache-dir --upgrade pip setuptools wheel
159
166
160
167
# install the rest of the packages including medcat
161
168
COPY ./requirements.txt /srv/jupyterhub/
0 commit comments