summaryrefslogtreecommitdiff
path: root/recipes-connectivity/lora/lora-packet-forwarder
diff options
context:
space:
mode:
authorJason Reiss <jreiss@multitech.com>2018-07-31 14:25:23 -0500
committerJason Reiss <jreiss@multitech.com>2018-07-31 14:25:23 -0500
commit8b44a4cb9e7e0e1801a48025b476eb4572a6dabf (patch)
treefae4788c27f9fb3eb518460f162774a86f97b487 /recipes-connectivity/lora/lora-packet-forwarder
parentf726b5a5528a385d22ee4e1d7d0adce92ab40fad (diff)
downloadmeta-mlinux-8b44a4cb9e7e0e1801a48025b476eb4572a6dabf.tar.gz
meta-mlinux-8b44a4cb9e7e0e1801a48025b476eb4572a6dabf.tar.bz2
meta-mlinux-8b44a4cb9e7e0e1801a48025b476eb4572a6dabf.zip
lora: update packet forwarder init script to update global_conf file inline
Diffstat (limited to 'recipes-connectivity/lora/lora-packet-forwarder')
-rwxr-xr-xrecipes-connectivity/lora/lora-packet-forwarder/lora-packet-forwarder.init4
1 files changed, 2 insertions, 2 deletions
diff --git a/recipes-connectivity/lora/lora-packet-forwarder/lora-packet-forwarder.init b/recipes-connectivity/lora/lora-packet-forwarder/lora-packet-forwarder.init
index 5ca2da9..4780da6 100755
--- a/recipes-connectivity/lora/lora-packet-forwarder/lora-packet-forwarder.init
+++ b/recipes-connectivity/lora/lora-packet-forwarder/lora-packet-forwarder.init
@@ -184,10 +184,10 @@ do_start() {
cp $conf_file $run_dir/1/
if [ -f $conf_file_local ]; then
cp $conf_file_local $run_dir/1/
- sed "s/\(.*gateway_ID\"\s*\:\s*\"\)<.*>[^\"]*\(.*\)/\1${lora_eui_raw}\2/g" /var/run/lora/1/local_conf.json
+ sed -i.bak "s/\(.*gateway_ID\"\s*\:\s*\"\)<.*>[^\"]*\(.*\)/\1${lora_eui_raw}\2/g" /var/run/lora/1/local_conf.json
fi
- sed "s/\(.*gateway_ID\"\s*\:\s*\"\)<.*>[^\"]*\(.*\)/\1${lora_eui_raw}\2/g" /var/run/lora/1/global_conf.json
+ sed -i.bak "s/\(.*gateway_ID\"\s*\:\s*\"\)<.*>[^\"]*\(.*\)/\1${lora_eui_raw}\2/g" /var/run/lora/1/global_conf.json
#
# start packet forwarder