You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It would be nice to have "latest-and-greatest" python on terra. A terra VM is essentially a docker container. There are no sudo privileges. (Based on previous attempts, this may not be realistic and we will need to settle for 3.10)
Contact terra support
This untested script may work
#!/bin/bash
# Set the desired Python version
PYTHON_VERSION="3.12.0"
# Set the installation directory
INSTALL_DIR="$HOME/python$PYTHON_VERSION"
# URL to the Python source code tarball
PYTHON_URL="https://www.python.org/ftp/python/$PYTHON_VERSION/Python-$PYTHON_VERSION.tar.xz"
# Download Python source code
wget "$PYTHON_URL" -O Python-$PYTHON_VERSION.tar.xz
# Extract the tarball
tar -xvf Python-$PYTHON_VERSION.tar.xz
# Navigate to the extracted directory
cd Python-$PYTHON_VERSION
# Configure and install Python locally
./configure --prefix="$INSTALL_DIR"
make
make install
# Update PATH
echo 'export PATH=$HOME/python'"$PYTHON_VERSION"'/bin:$PATH' >> ~/.bashrc
source ~/.bashrc
# Display Python version
python3.12 --version
# Clean up - remove the downloaded tarball and extracted directory
cd ..
rm -rf Python-$PYTHON_VERSION
rm Python-$PYTHON_VERSION.tar.xz
The text was updated successfully, but these errors were encountered:
It would be nice to have "latest-and-greatest" python on terra. A terra VM is essentially a docker container. There are no sudo privileges. (Based on previous attempts, this may not be realistic and we will need to settle for 3.10)
The text was updated successfully, but these errors were encountered: