mirror of
https://github.com/sdr-enthusiasts/docker-planefence.git
synced 2025-12-22 11:17:06 +00:00
update link
This commit is contained in:
@@ -174,7 +174,7 @@ GET_PS_PHOTO () {
|
||||
local link
|
||||
|
||||
if [[ -f "/usr/share/planefence/persist/planepix/cache/$1.jpg" ]]; then
|
||||
echo "/usr/share/planefence/persist/planepix/cache/$1.jpg"
|
||||
echo "imgcache/$1.jpg"
|
||||
return 0
|
||||
fi
|
||||
# If we don't have a cache file, let's see if we can get one from PlaneSpotters.net
|
||||
@@ -183,7 +183,7 @@ GET_PS_PHOTO () {
|
||||
&& [[ -n "$link" ]]; then
|
||||
# If we have a link, let's download the photo
|
||||
curl -ssL --fail "$link" -o "/usr/share/planefence/persist/planepix/cache/$1.jpg"
|
||||
echo "/usr/share/planefence/persist/planepix/cache/$1.jpg"
|
||||
echo "imgcache/$1.jpg"
|
||||
else
|
||||
# If we don't have a link, let's return an empty string
|
||||
echo ""
|
||||
|
||||
@@ -60,6 +60,8 @@ chmod u=rwx,go=rx \
|
||||
/usr/share/planefence/html/plane-alert/silhouettes \
|
||||
/usr/share/planefence/html/scripts
|
||||
ln -sf /usr/share/planefence/html/scripts /usr/share/planefence/html/plane-alert/scripts
|
||||
ln -sf /usr/share/planefence/persist/planepix/cache /usr/share/planefence/html/imgcache
|
||||
chmod a+rx /usr/share/planefence/html/imgcache
|
||||
if [[ -f /usr/share/planefence/persist/planefence.config ]]; then
|
||||
set -o allexport
|
||||
# shellcheck disable=SC1091
|
||||
|
||||
Reference in New Issue
Block a user