#!/bin/bash
sudo apt-get update -y
sudo apt-get upgrade -y
sudo apt install -y python-pip curl libssl-dev libcurl4-openssl-dev libjpeg-dev
sudo apt install -y motion
sudo pip install motioneye
mkdir -p /etc/motioneye
cp /usr/local/share/motioneye/extra/motioneye.conf.sample /etc/motioneye/motioneye.conf
mkdir -p /var/lib/motioneye
cp /usr/local/share/motioneye/extra/motioneye.systemd-unit-local /etc/systemd/system/motioneye.service
systemctl daemon-reload
systemctl enable motioneye
systemctl start motioneye
をメモ帳なんかで開いてコピペして貼り付けてmotioneye.sh付けて
/home/piのところに保存しとけばいつでもアプデorインスコ出来るようになります。
そしてsudo bash /home/pi/motioneye.shで実行