-
Notifications
You must be signed in to change notification settings - Fork 0
/
base-os.sh
113 lines (87 loc) · 2.38 KB
/
base-os.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
#!/usr/bin/env bash
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
if [ -z "NO_PASSWORDLESS" ]; then
# Passwordless sudo:
bash ./nopasswd.sh
fi
if [ -z "NO_SSH" ]; then
# SSH Keys (known to GitHub):
bash ./inst-keys.sh
fi
# Common System packages:
$SUDO apt update
$SUDO apt install -y linux-headers-$(uname -r)
$SUDO apt install -y apt-utils build-essential git-core autoconf automake cmake libtool openssh-server
$SUDO apt install -y libcurl4-openssl-dev libxml2-dev libfuse-dev libffi-dev libssl-dev libbz2-dev lzma liblzma-dev
$SUDO apt install -y libsqlite3-dev zlib1g-dev libncurses5-dev libgdbm-dev libnss3-dev libreadline-dev nfs-common
$SUDO apt install -y python3-pip virtualenv vim tree git curl wget terminator baobab htop cpu-checker gnome-tweaks chrome-gnome-shell ufw
cat <<EOT >> ~/.bashrc
set -a
renv() {
source $HOME/.bashrc
}
gget() {
echo "gdown https://drive.google.com/uc?id=$1 -O $2"
gdown https://drive.google.com/uc?id=$1 -O $2
}
ggetf() {
echo "gdown https://drive.google.com/drive/folders/$1 -O $2 --folder"
gdown https://drive.google.com/drive/folders/$1 -O $2 --folder
}
set +a
EOT
pip3 install virtualenvwrapper gdown
echo 'export PATH=$HOME/.local/bin:$PATH' >> ~/.bashrc
git config --global url."[email protected]:".insteadOf "https://github.com/"
git config --global user.email "[email protected]"
git config --global user.name "Aaron Cody"
git config --global push.default simple
if [ -z "NO_NVIDIA_DRIVER" ]; then
# NVidia driver
bash ./inst-nvidia-pkg.sh
fi
if [ -z "NO_NVIDIA_CUDA" ]; then
# CUDA Toolkit
bash ./inst-cuda-11.0.3.sh
# cuDNN
bash ./inst-cudnn-11.0.3.sh
fi
if [ -z "NO_DOCKER" ]; then
# Docker
bash ./inst-docker-ce.sh
# NVidia docker
bash ./inst-nvdocker.sh
fi
if [ -z "NO_MATHEMATICA" ]; then
# Mathematica
bash ./inst-mathematica.sh
fi
if [ -z "NO_VM" ]; then
# VM Software
bash ./inst-vkm.sh
bash ./inst-vbox.sh
fi
if [ -z "NO_SUBLIME" ]; then
# Sublime Text
bash ./inst-sublime.sh
fi
if [ -z "NO_VSCODE" ]; then
# VSCode
bash ./inst-vscode.sh
fi
if [ -z "NO_BREW" ]; then
# Brew
bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
fi
if [ -z "NO_NVTOP" ]; then
# NVTop
bash ./inst-nvtop.sh
fi
if [ -z "NO_NOMACHINE" ]; then
# NoMachine
bash ./inst-nomachine.sh
fi
if [ -z "NO_TERRAFORM" ]; then
# NoMachine
bash ./inst-terraform.sh
fi