Skip to content

Commit

Permalink
feat(feed): fix bad config
Browse files Browse the repository at this point in the history
  • Loading branch information
Thom-x committed Oct 20, 2023
1 parent a16cd3d commit c09bfec
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
9 changes: 4 additions & 5 deletions root/etc/s6-overlay/s6-rc.d/conf-adsbhub/script
Original file line number Diff line number Diff line change
@@ -1,16 +1,15 @@
#!/command/with-contenv bash

if [ "$SERVICE_ENABLE_ADSBHUB" != "false" ]; then
set -eo pipefail
if [ -z "$ADSBHUB_CKEY" ]; then
for i in {1..5}; do
echo "FATAL: ADSBHUB_CKEY not set!" | mawk -W interactive '{printf "%c[33m[adsbhub]%c[0m %s\n", 27, 27, $0}'
done
kill 1
exit 1
fi

cd /usr/bin
wget https://www.adsbhub.org/downloads/adsbhub.php --no-check-certificate -O adsbhub.sh
chmod 755 adsbhub.sh
sed -i "s/^ckey=.*/ckey=$ADSBHUB_CKEY/" "adsbhub.sh"
wget https://www.adsbhub.org/downloads/adsbhub.php --no-check-certificate -O /usr/bin/adsbhub.sh
chmod 755 /usr/bin/adsbhub.sh
sed -i "s/^ckey=.*/ckey=$ADSBHUB_CKEY/" "/usr/bin/adsbhub.sh"
fi
2 changes: 1 addition & 1 deletion root/etc/s6-overlay/s6-rc.d/conf-adsbhub/up
Original file line number Diff line number Diff line change
@@ -1 +1 @@
/etc/s6-overlay/s6-rc.d/confd-piaware/script
/etc/s6-overlay/s6-rc.d/conf-adsbhub/script

0 comments on commit c09bfec

Please sign in to comment.