Skip to content
This repository has been archived by the owner on Oct 30, 2019. It is now read-only.

Fixed problem when running on stretch #47

Merged
merged 2 commits into from
Sep 23, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions package/opt/hassbian/suites/install_mosquitto.sh
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,30 @@ echo "Installing mosquitto"
apt-get update
apt install -y mosquitto mosquitto-clients


if [[ $? > 0 ]]
then
echo "First try failed, adding dependencies and trying again."
echo "This is an workaround and will be omited once it's fixed upstream."
echo "Downloading dependencies"
cd
wget http://ftp.se.debian.org/debian/pool/main/o/openssl/libssl1.0.0_1.0.1t-1+deb8u6_armhf.deb
wget http://ftp.se.debian.org/debian/pool/main/libw/libwebsockets/libwebsockets3_1.2.2-1_armhf.deb

echo "Installing dependencies"
sudo dpkg -i libssl1.0.0_1.0.1t-1+deb8u6_armhf.deb
sudo dpkg -i libwebsockets3_1.2.2-1_armhf.deb

echo "Cleanup dependencies"
rm libssl1.0.0_1.0.1t-1+deb8u6_armhf.deb
rm libwebsockets3_1.2.2-1_armhf.deb

echo "Retrying installation of mosquitto"
apt install -y mosquitto mosquitto-clients
else
echo ""
fi

echo "Writing default configuration"
cd /etc/mosquitto
mv mosquitto.conf mosquitto.conf.backup
Expand Down