Merge branch 'new-schema'

The Rust portions of the merge are straightforward, but the Javascript
is not. The new-schema branch is based on my hacky prototype UI; the
master branch is based on Dolf's rewrite. I attempted to match the
new-schema changes in Dolf's new structure.
This commit is contained in:
Scott Lamb
2018-04-27 06:42:39 -07:00
67 changed files with 8771 additions and 4588 deletions

View File

@@ -359,25 +359,6 @@ fix_localtime()
fi
}
# Add/update cameras in the database
#
# $1: path to cameras.sql file
# $2: moonfire service name
# $3: moonfire user name
# $4: moonfire database path
#
addCameras()
{
local cpath="${CAMERAS_PATH:-$1}"
if [ -r "${cpath}" ]; then
echo_info -x 'Add cameras...'
# Before adding cameras, must stop service
moonfire stop "${SERVICE_NAME:-$2}" >/dev/null 2>&1
sudo -u ${NVR_USER:-$3} -H sqlite3 "${DB_PATH:-$4}" < "${cpath}"
moonfire start "${SERVICE_NAME:-$2}" >/dev/null 2>&1
fi
}
pre_install_prep()
{
prep_moonfire_user