Last active
November 18, 2020 15:57
-
-
Save dariuszparys/14f1039dc0e71aae61240b7fdfefa1b4 to your computer and use it in GitHub Desktop.
Prepare Testinfra Debian 10 Dev-Box
This file contains 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 install -y \ | |
build-essential \ | |
zlib1g-dev \ | |
libncurses5-dev \ | |
libgdbm-dev \ | |
libnss3-dev \ | |
libssl-dev \ | |
libsqlite3-dev \ | |
libreadline-dev \ | |
libffi-dev \ | |
curl \ | |
libbz2-dev \ | |
apt-transport-https \ | |
ca-certificates \ | |
gnupg-agent \ | |
software-properties-common \ | |
vim | |
mkdir -p ~/tmp/downloads | |
cd ~/tmp/downloads | |
# Install Python 3.6.12 | |
curl -O https://www.python.org/ftp/python/3.6.12/Python-3.6.12.tar.xz | |
tar -xf Python-3.6.12.tar.xz | |
cd Python-3.6.12 | |
./configure --enable-optimizations | |
make -j "$(nproc)" | |
sudo make altinstall | |
# Install Python 3.7.9 | |
cd ~/tmp/downloads | |
curl -O https://www.python.org/ftp/python/3.7.9/Python-3.7.9.tar.xz | |
tar -xf Python-3.7.9.tar.xz | |
cd Python-3.7.9 | |
./configure --enable-optimizations | |
make -j "$(nproc)" | |
sudo make altinstall | |
# Install Python 3.8.6 | |
cd ~/tmp/downloads | |
curl -O https://www.python.org/ftp/python/3.8.6/Python-3.8.6.tar.xz | |
tar -xf Python-3.8.6.tar.xz | |
cd Python-3.8.6 | |
./configure --enable-optimizations | |
make -j "$(nproc)" | |
sudo make altinstall | |
# Install Python 3.9.0 | |
cd ~/tmp/downloads | |
curl -O https://www.python.org/ftp/python/3.9.0/Python-3.9.0.tar.xz | |
tar -xf Python-3.9.0.tar.xz | |
cd Python-3.9.0 | |
./configure --enable-optimizations | |
make -j "$(nproc)" | |
sudo make altinstall | |
# Install Docker Engine | |
cd ~/tmp/downloads | |
curl -fsSL https://download.docker.com/linux/debian/gpg | sudo apt-key add - | |
sudo add-apt-repository \ | |
"deb [arch=amd64] https://download.docker.com/linux/debian \ | |
$(lsb_release -cs) \ | |
stable" | |
sudo apt-get update | |
sudo apt-get -y install docker-ce docker-ce-cli containerd.io | |
# logout and login after adding user to docker group | |
sudo usermod -aG docker $USER | |
cd ~ | |
# delete the tmp folder | |
# rm -rf ~/tmp |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment