-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.sh
50 lines (41 loc) · 1.42 KB
/
setup.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
#! /bin/sh
#
# Set up script for a new DEEPi System
# Enable SSH
sudo touch /boot/ssh
# Enable camera
sudo sh -c "echo '[all] # Enabling camera' >> /boot/config.txt"
sudo sh -c "echo 'start_x=1' >> /boot/config.txt"
sudo sh -c "echo 'gpu_mem=256' >> /boot/config.txt"
#sudo sh -c "echo 'dissable_camera_led=1' >> /boot/config.txt"
# Update RPi
sudo apt-get -y update
# sudo apt-get -y upgrade
sudo apt-get -y autoremove
# Install supporting packages
sudo apt-get -y install proftpd-basic # TODO: check out pureftp
# https://www.raspberrypi.com/documentation/computers/remote-access.html
sudo apt-get -y install ntp
sudo apt-get -y install ffmpeg
sudo apt-get -y install git
sudo apt-get -y install nginx
sudo apt-get -y install emacs-nox
# Install Python
sudo apt-get -y install python3-setuptools python3-dev build-essential libpq-dev
sudo apt-get -y install python3-virtualenv
sudo apt-get -y install python3-picamera
# Install pip
sudo apt-get install python3-pip
python -m pip install --upgrade pip setuptools wheel build
# Install python requirements
sudo apt-get install rpi.gpio
python -m pip install RPi.GPIO
python -m pip install ws4py flask pyyaml
python -m pip install picamera
# Set up deployment service
sudo cp deepi.service /usr/lib/systemd/system/deepi.service
sudo systemctl daemon-reload
sudo systemctl start deepi.service
sudo systemctl enable deepi.service
# sudo systemctl status deepi.service
cp deepi.conf ~/deepi.conf