Last active
November 29, 2024 06:42
-
-
Save pRoy24/d8424c62cf35ab5840d6a53036b5c379 to your computer and use it in GitHub Desktop.
Prerequisites to setup a bare-metal Ubuntu GPU instance for running CUDA generative AI inference platforms such as Stable Diffusion, Gradio etc.
This file contains hidden or 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
#!/bin/bash | |
sudo apt-get update && sudo apt-get upgrade -y | |
sudo apt install software-properties-common build-essential ffmpeg libsm6 libxext6 zlib1g-dev libncurses5-dev libgdbm-dev libnss3-dev libssl-dev libreadline-dev libffi-dev libsqlite3-dev wget libbz2-dev liblzma-dev ffmpeg libsm6 libxext6 -y | |
sudo add-apt-repository ppa:deadsnakes/ppa -y | |
sudo apt install python3.10 -y | |
sudo apt install python3.10-venv -y | |
curl -s https://ngrok-agent.s3.amazonaws.com/ngrok.asc | sudo tee /etc/apt/trusted.gpg.d/ngrok.asc >/dev/null && echo "deb https://ngrok-agent.s3.amazonaws.com buster main" | sudo tee /etc/apt/sources.list.d/ngrok.list && sudo apt update && sudo apt install ngrok | |
# Alernative way to install python3.10 if the above method fails | |
# VERSION=3.10.6 | |
# wget https://www.python.org/ftp/python/$VERSION/Python-$VERSION.tgz | |
# tar -xf Python-$VERSION.tgz | |
# cd Python-$VERSION/ | |
# ./configure --enable-optimizations | |
# make -j $(nproc) | |
# sudo make altinstall | |
ngrok config add-authtoken {auth_token} | |
sudo apt install vim -y | |
pip installl python3.10-dev | |
python3.10 -m venv venv | |
source ./venv/bin/activate |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment