Install rewrite v2

This commit is contained in:
Jokob-sk
2023-10-29 22:10:53 +11:00
parent 9f5884c4e7
commit baec65fde7
11 changed files with 72 additions and 54 deletions

View File

@@ -4,8 +4,7 @@ echo "---------------------------------------------------------"
echo "[INSTALL] Run install_dependencies.sh"
echo "---------------------------------------------------------"
# Set environment variables
INSTALL_DIR=/home/pi # Specify the installation directory here
# ❗ IMPORTANT - if you modify this file modify the root Dockerfile as well ❗
# Check if script is run as root
if [[ $EUID -ne 0 ]]; then
@@ -13,19 +12,22 @@ if [[ $EUID -ne 0 ]]; then
exit 1
fi
# Install dependencies
apt-get install -y \
tini snmp ca-certificates curl libwww-perl arp-scan perl apt-utils cron sudo \
nginx-light php php-cgi php-fpm php-sqlite3 php-curl sqlite3 dnsutils net-tools \
python3 iproute2 nmap python3-pip zip systemctl usbutils traceroute
# ---------------------------------------------------------------
# alternate dependencies
# sudo apt-get install mtr-tiny -y
sudo apt-get install nginx nginx-core mtr php-fpm php8.2-fpm -y
sudo apt-get install php-cli php8.2 php8.2-fpm -y
sudo apt-get install php8.2-sqlite3 -y
sudo apt-get install nginx nginx-core mtr php-fpm php8.2-fpm php-cli php8.2 php8.2-sqlite3 -y
sudo phpenmod -v 8.2 sqlite3
# sudo apt-get install net-tools -y
# ---------------------------------------------------------------
# setup virtual python environment so we can use pip3 to install packages
apt-get install python3.11-venv -y
python3 -m venv myenv
source myenv/bin/activate
update-alternatives --install /usr/bin/python python /usr/bin/python3 10
# install packages thru pip3
pip3 install requests paho-mqtt scapy cron-converter pytz json2table dhcp-leases pyunifi speedtest-cli chardet