Skip to content

Commit

Permalink
rearranging dirs
Browse files Browse the repository at this point in the history
  • Loading branch information
ampledata committed Jun 19, 2024
1 parent 4676bd6 commit bd4bbc7
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 0 deletions.
Empty file.
33 changes: 33 additions & 0 deletions debian/usr/bin/adsbxfeed.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
#!/bin/bash

source /boot/adsbxfeed.txt

if ! [[ -d /run/adsbxfeed/ ]]; then
mkdir -p /run/adsbxfeed
fi

if [[ -z $INPUT ]]; then
INPUT="127.0.0.1:30005"
fi

INPUT_IP=$(echo $INPUT | cut -d: -f1)
INPUT_PORT=$(echo $INPUT | cut -d: -f2)
SOURCE="--net-connector $INPUT_IP,$INPUT_PORT,beast_in,silent_fail"

if [[ -z $UAT_INPUT ]]; then
UAT_INPUT="127.0.0.1:30978"
fi

UAT_IP=$(echo $UAT_INPUT | cut -d: -f1)
UAT_PORT=$(echo $UAT_INPUT | cut -d: -f2)
UAT_SOURCE="--net-connector $UAT_IP,$UAT_PORT,uat_in,silent_fail"


exec /usr/bin/readsb --net --net-only --quiet \
--write-json /run/adsbxfeed \
--net-beast-reduce-interval $REDUCE_INTERVAL \
$TARGET $NET_OPTIONS \
--lat "$LATITUDE" --lon "$LONGITUDE" \
$UUID_FILE $JSON_OPTIONS \
$UAT_SOURCE \
$SOURCE \

0 comments on commit bd4bbc7

Please sign in to comment.