summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMaurice Kalinowski <maurice.kalinowski@qt.io>2018-01-29 16:03:57 +0100
committerMaurice Kalinowski <maurice.kalinowski@qt.io>2018-02-02 06:22:49 +0000
commite33f38acef89e72d1895ca45e3beda70f41c9b83 (patch)
tree97a095c35ae4bf6c6f30cb20b1286653de3ec313
parent351a519340d509300c754d0a62771a7f6e38ea4c (diff)
Update MQTT provisioning
Setting an environment variable has been centralized to a separate script. Change-Id: I027f9a71d32ee7f7d68575c9433f56a40a369deb Reviewed-by: Heikki Halmet <heikki.halmet@qt.io>
-rw-r--r--coin/provisioning/common/unix/mqtt_broker.sh5
1 files changed, 4 insertions, 1 deletions
diff --git a/coin/provisioning/common/unix/mqtt_broker.sh b/coin/provisioning/common/unix/mqtt_broker.sh
index c2fb2e30..59dd7009 100644
--- a/coin/provisioning/common/unix/mqtt_broker.sh
+++ b/coin/provisioning/common/unix/mqtt_broker.sh
@@ -37,6 +37,7 @@
# shellcheck source=./InstallFromCompressedFileFromURL.sh
source "${BASH_SOURCE%/*}/InstallFromCompressedFileFromURL.sh"
+source "${BASH_SOURCE%/*}/../unix/SetEnvVar.sh"
CommitSHA="c342c09dadc7a664d0a8befad1ca031f5a0b0bc0"
PrimaryUrl="https://github.com/eclipse/paho.mqtt.testing/archive/$CommitSHA.zip"
@@ -49,4 +50,6 @@ sudo rm -fr "$targetFolder"
InstallFromCompressedFileFromURL "$PrimaryUrl" "$AltUrl" "$SHA1" "$targetFolder" "$appPrefix"
echo "Adding MQTT broker path to environment"
-sed -i "1iexport MQTT_TEST_BROKER_LOCATION=$targetFolder/interoperability/startbroker.py" ~/.bashrc
+SetEnvVar "MQTT_TEST_BROKER_LOCATION" "$targetFolder/interoperability/startbroker.py"
+
+echo "MQTT_BROKER = $CommitSHA" >> ~/versions.txt