update
This commit is contained in:
12
README.md
12
README.md
@@ -9,12 +9,18 @@ Based on the Rpi4 or CM4.
|
||||
You can download the `installation_part1.sh` and run it:
|
||||
```
|
||||
wget http://gitea.aircarto.fr/PaulVua/nebuleair_pro_4g/raw/branch/main/installation_part1.sh
|
||||
chmod +x installation.sh
|
||||
sudo ./installation.sh
|
||||
chmod +x installation_part1.sh
|
||||
sudo ./installation_part1.sh
|
||||
```
|
||||
|
||||
After reboot you can do the same with part 2.
|
||||
|
||||
```
|
||||
wget http://gitea.aircarto.fr/PaulVua/nebuleair_pro_4g/raw/branch/main/installation_part2.sh
|
||||
chmod +x installation_part2.sh
|
||||
sudo ./installation_part2.sh
|
||||
```
|
||||
|
||||
|
||||
## General
|
||||
|
||||
@@ -23,7 +29,7 @@ Line by line installation.
|
||||
```
|
||||
sudo apt update
|
||||
sudo apt install git gh apache2 php php-sqlite3 python3 python3-pip jq autossh i2c-tools python3-smbus -y
|
||||
sudo pip3 install pyserial requests RPi.GPIO adafruit-circuitpython-bme280 crcmod psutil --break-system-packages
|
||||
sudo pip3 install pyserial requests RPi.GPIO adafruit-circuitpython-bme280 crcmod psutil ntplib pytz --break-system-packages
|
||||
sudo mkdir -p /var/www/.ssh
|
||||
sudo ssh-keygen -t rsa -b 4096 -f /var/www/.ssh/id_rsa -N ""
|
||||
sudo ssh-copy-id -i /var/www/.ssh/id_rsa.pub -p 50221 airlab_server1@aircarto.fr
|
||||
|
||||
@@ -27,7 +27,7 @@ sudo apt update && sudo apt install -y git gh apache2 php php-sqlite3 python3 py
|
||||
|
||||
# Install Python libraries
|
||||
info "Installing Python libraries..."
|
||||
sudo pip3 install pyserial requests RPi.GPIO adafruit-circuitpython-bme280 crcmod psutil --break-system-packages || error "Failed to install Python libraries."
|
||||
sudo pip3 install pyserial requests RPi.GPIO adafruit-circuitpython-bme280 crcmod psutil ntplib pytz --break-system-packages || error "Failed to install Python libraries."
|
||||
|
||||
# Ask user if they want to set up SSH keys
|
||||
read -p "Do you want to set up an SSH key for /var/www? (y/n): " answer
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Script to set up the App after rebooting
|
||||
|
||||
# Exit on error, unset variable usage, and error in a pipeline
|
||||
set -euo pipefail
|
||||
|
||||
@@ -21,6 +23,9 @@ if [[ "$EUID" -ne 0 ]]; then
|
||||
error "This script must be run as root. Use 'sudo ./installation.sh'"
|
||||
fi
|
||||
|
||||
#set up the RTC
|
||||
info "Set up the RTC"
|
||||
/usr/bin/python3 /var/www/nebuleair_pro_4g/RTC/set_with_NTP.py
|
||||
|
||||
#set up SARA R4 APN
|
||||
info "Set up Monogoto APN"
|
||||
|
||||
Reference in New Issue
Block a user