This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Run the file on boot; | |
# | |
# nano /etc/crontab | |
# @reboot root /path/to/script.sh | |
# | |
from picamera import PiCamera | |
from time import sleep | |
import time | |
import os |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
input { | |
elasticsearch { | |
hosts => [ "HOSTNAME_HERE" ] | |
port => "9200" | |
index => "INDEXNAME_HERE" | |
size => 1000 | |
scroll => "5m" | |
docinfo => true | |
scan => true | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# upgrade raspi-config | |
sudo raspi-config | |
# Install all the essentails required to get motioneye working. | |
# The command fails as ffmpeg does not exist on rpi repository, so you need to download and build it from scratch | |
apt-get install build-essential autoconf libjpeg-dev libavformat-dev libavcodec-dev libswscale-dev ffmpeg subversion git | |
sudo apt-get install build-essential autoconf libjpeg-dev libavformat-dev libavcodec-dev libswscale-dev ffmpeg subversion git | |
# Install ffmpeg source and compile |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Help menu for the script. | |
usage () { | |
echo "Usage: `basename $0` [-h] [-b] [-d] [-r] [-i] [-s] [http://es-ESname:9200]" | |
echo "" | |
echo "where: " | |
echo " -h Show this help text " | |
echo " -b Backup the elasticsearch indices to .json files " | |
echo " -d Delete the indices backed up" |