This commit is contained in:
Ray Ozzie 2016-03-22 12:09:41 -07:00
parent be08efa9dd
commit b043882c15
2 changed files with 14 additions and 5 deletions

View File

@ -65,8 +65,8 @@ fi
# create local.conf
echo -e "{\n\\
t\"gateway_conf\": {\n\
echo -e "{\n\
\t\"gateway_conf\": {\n\
\t\t\"gateway_ID\": \"0000000000000000\",\n\
\t\t\"ref_latitude\": $GATEWAY_LAT,\n\
\t\t\"ref_longitude\": $GATEWAY_LON,\n\

View File

@ -52,9 +52,9 @@ echo ""
# load the region-appropriate global conf
if curl --fail https://raw.githubusercontent.com/rayozzie/ttn-gateway-conf/master/$GATEWAY_REGION-global-conf.json --output ./global-conf.json
if curl --fail https://raw.githubusercontent.com/rayozzie/ttn-gateway-conf/master/$GATEWAY_REGION-global_conf.json --output ./global_conf.json
then
echo Successfully loaded $GATEWAY_REGION-global-conf.json from TTN repo
echo Successfully loaded $GATEWAY_REGION-global_conf.json from TTN repo
else
echo "******************"
echo "ERROR: GATEWAY_REGION not found"
@ -65,7 +65,16 @@ fi
# create local.conf
echo -e "{\n\t\"gateway_conf\": {\n\t\t\"gateway_ID\": \"0000000000000000\",\n\t\t\"ref_latitude\": $GATEWAY_LAT,\n\t\t\"ref_longitude\": $GATEWAY_LON,\n\t\t\"ref_altitude\": $GATEWAY_ALT,\n\t\t\"contact_email\": \"$GATEWAY_EMAIL\",\n\t\t\"description\": \"$GATEWAY_NAME\" \n\t}\n}" >./local_conf.json
echo -e "{\n\\
t\"gateway_conf\": {\n\
\t\t\"gateway_ID\": \"0000000000000000\",\n\
\t\t\"ref_latitude\": $GATEWAY_LAT,\n\
\t\t\"ref_longitude\": $GATEWAY_LON,\n\
\t\t\"ref_altitude\": $GATEWAY_ALT,\n\
\t\t\"contact_email\": \"$GATEWAY_EMAIL\",\n\
\t\t\"description\": \"$GATEWAY_NAME\" \n\
\t}\n\
}" >./local_conf.json
# Reset gateway ID based on MAC