Directly include the VRS-derived json db since the underlying DB
is not being updated any more.
This commit is contained in:
parent
577fe9b52e
commit
108b402918
69 changed files with 73 additions and 26 deletions
3
debian/dump1090-mutability.install
vendored
3
debian/dump1090-mutability.install
vendored
|
|
@ -2,6 +2,3 @@ public_html/* usr/share/dump1090-mutability/html
|
|||
debian/lighttpd/* etc/lighttpd/conf-available
|
||||
debian/nginx/* etc/nginx/sites-available
|
||||
debian/config-template usr/share/dump1090-mutability
|
||||
debian/cron-template usr/share/dump1090-mutability
|
||||
tools/vrs-basicaircraft-to-json.py usr/share/dump1090-mutability
|
||||
tools/update-aircraft-database.sh usr/share/dump1090-mutability
|
||||
|
|
|
|||
23
debian/dump1090-mutability.postinst
vendored
23
debian/dump1090-mutability.postinst
vendored
|
|
@ -120,26 +120,11 @@ case "$1" in
|
|||
touch $RET
|
||||
chown $RUNAS $RET
|
||||
|
||||
# create cronjob
|
||||
if ! test -e $CRONFILE; then
|
||||
echo "Creating cronjob in $CRONFILE to periodically update the aircraft database.." >&2
|
||||
MIN=$(($RANDOM % 60))
|
||||
tail -n +4 $TEMPLATECRON | sed -e "s/@USER@/$RUNAS/g" -e "s/@MIN@/$MIN/g" >$CRONFILE
|
||||
fi
|
||||
|
||||
# update the DB
|
||||
echo "Updating aircraft database now.."
|
||||
mkdir -m 0755 -p /var/cache/$NAME
|
||||
chown $RUNAS /var/cache/$NAME
|
||||
su $RUNAS -s /bin/bash -c /usr/share/$NAME/update-aircraft-database.sh || \
|
||||
echo "Aircraft database update failed. It will be retried periodically from cron." >&2
|
||||
|
||||
# config file changed between 1.14 and 1.15
|
||||
# this config file has changed a few times, restart lighttpd to make sure we
|
||||
# have the latest version
|
||||
if [ -e /etc/lighttpd/conf-enabled/89-dump1090.conf ]; then
|
||||
if dpkg --compare-versions "$2" le "1.14"; then
|
||||
echo "Restarting lighttpd.." >&2
|
||||
invoke-rc.d lighttpd restart || echo "Warning: lighttpd failed to restart." >&2
|
||||
fi
|
||||
echo "Restarting lighttpd.." >&2
|
||||
invoke-rc.d lighttpd restart || echo "Warning: lighttpd failed to restart." >&2
|
||||
fi
|
||||
;;
|
||||
|
||||
|
|
|
|||
1
debian/lighttpd/89-dump1090.conf
vendored
1
debian/lighttpd/89-dump1090.conf
vendored
|
|
@ -9,7 +9,6 @@ url.redirect += (
|
|||
|
||||
alias.url += (
|
||||
"/dump1090/data/" => "/run/dump1090-mutability/",
|
||||
"/dump1090/db/" => "/var/cache/dump1090-mutability/db/",
|
||||
"/dump1090/" => "/usr/share/dump1090-mutability/html/"
|
||||
)
|
||||
|
||||
|
|
|
|||
3
debian/nginx/dump1090-mutability
vendored
3
debian/nginx/dump1090-mutability
vendored
|
|
@ -12,8 +12,5 @@ server{
|
|||
location /dump1090/data/ {
|
||||
alias /run/dump1090-mutability/;
|
||||
}
|
||||
location /dump1090/db/ {
|
||||
alias /var/cache/dump1090-mutability/db/;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue