2020-03-06 01:23:20 +01:00
|
|
|
import subprocess
|
|
|
|
|
|
|
|
|
2020-03-06 02:34:57 +01:00
|
|
|
class ToolsInstaller:
|
2020-03-06 01:23:20 +01:00
|
|
|
|
2020-03-06 02:34:57 +01:00
|
|
|
def basic_tools(self):
|
2020-03-06 01:23:20 +01:00
|
|
|
"""Install the most basic tools!"""
|
|
|
|
print("Try to install basic Command-line tools")
|
2020-03-21 04:11:14 +01:00
|
|
|
subprocess.run("apt-get install -y bleachbit nano xrdp htop bash-completion dialog powertop tree wget",
|
|
|
|
shell=True)
|
2020-03-06 01:23:20 +01:00
|
|
|
print("Script ran to completion.")
|
|
|
|
|
|
|
|
def hard_drive_tools(self):
|
|
|
|
"""Install tools to look up smart information from your hard-drives"""
|
2020-03-11 00:41:17 +01:00
|
|
|
subprocess.run("apt-get install -y smartmontools gsmartcontrol", shell=True)
|
2020-03-10 23:02:33 +01:00
|
|
|
|
|
|
|
def docker(self):
|
|
|
|
"""Install the Docker service on the machine"""
|
2020-03-21 04:07:53 +01:00
|
|
|
subprocess.run("curl -fsSL https://get.docker.com | bash", shell=True)
|
|
|
|
subprocess.run("curl -L \"https://github.com/docker/compose/releases/download/"
|
|
|
|
"1.25.4/docker-compose-$(uname -s)-$(uname -m)\" -o /usr/local/bin/docker-compose"
|
|
|
|
"&& chmod +x /usr/local/bin/docker-compose", shell=True)
|