Update to python3
[icn.git] / env / cd_package_installer.sh
1 #!/usr/bin/env bash
2 set -eux -o pipefail
3
4 if [[ $EUID -ne 0 ]]; then
5     echo "This script must be run as root"
6     exit 1
7 fi
8
9 function install_essential_packages {
10     export DEBIAN_FRONTEND=noninteractive
11     apt-get update
12     apt-get -y install \
13     crudini \
14     curl \
15     dnsmasq \
16     figlet \
17     nmap \
18     patch \
19     psmisc \
20     python3-pip \
21     python3-requests \
22     python3-setuptools \
23     vim \
24     wget \
25     git \
26     software-properties-common
27
28     update-alternatives --install /usr/bin/python python /usr/bin/python3 1
29     update-alternatives --install /usr/bin/pip pip /usr/bin/pip3 1
30
31     add-apt-repository -y ppa:longsleep/golang-backports
32     apt-get update
33     apt-get install -y golang-go
34 }
35
36 install_essential_packages