From 970370c198da1cc87b199807754695230c84b836 Mon Sep 17 00:00:00 2001 From: Nico Schottelius Date: Wed, 2 Dec 2020 13:04:08 +0100 Subject: [PATCH] ++openwrt scripts --- ...> openwrt-add-camera-with-mjpg-streamer.sh | 0 openwrt-add-camera-with-motion.sh | 52 +++++++++++++++++++ openwrt-add-jool.sh | 32 ++++++++++++ 3 files changed, 84 insertions(+) rename openwrt-add-camera.sh => openwrt-add-camera-with-mjpg-streamer.sh (100%) create mode 100755 openwrt-add-camera-with-motion.sh create mode 100644 openwrt-add-jool.sh diff --git a/openwrt-add-camera.sh b/openwrt-add-camera-with-mjpg-streamer.sh similarity index 100% rename from openwrt-add-camera.sh rename to openwrt-add-camera-with-mjpg-streamer.sh diff --git a/openwrt-add-camera-with-motion.sh b/openwrt-add-camera-with-motion.sh new file mode 100755 index 0000000..33d5fd3 --- /dev/null +++ b/openwrt-add-camera-with-motion.sh @@ -0,0 +1,52 @@ +#!/bin/sh + +if [ $# -lt 1 ]; then + echo "$0 ip-address" + echo " ip-address: where to find the device" + exit 1 +fi + + +set -x + +openwrt_ip=$1; shift + +ping -c3 ${openwrt_ip} +if [ $? -ne 0 ]; then + echo "Cannot reach ${openwrt_ip}, aborting" + exit 1 +fi + +cat < /etc/motion.conf <