Last active
June 12, 2019 18:52
-
-
Save dale3h/340c49ab8295876db2db73c40f99ae93 to your computer and use it in GitHub Desktop.
Hass.io Installer for Raspberry Pi 3 B+
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
########################################################### | |
########################################################### | |
## ## | |
## THIS SCRIPT SHOULD ONLY BE RUN ON A RASPBERRY PI 3 B+ ## | |
## ## | |
########################################################### | |
########################################################### | |
if [[ $EUID -ne 0 ]]; then | |
echo "This script must be run as root." | |
echo "Please try again with:" | |
echo " sudo $0" | |
exit 1 | |
fi | |
requirements=("socat" "jq" "curl" "avahi-daemon" "dbus-daemon") | |
missing= | |
for cmd in ${requirements[@]}; do | |
package="$cmd" | |
[[ "$cmd" == "dbus-daemon" ]] && package="dbus" | |
[[ $(command -v "$cmd") ]] || missing="$missing$package " | |
done | |
if [[ -n "$missing" ]]; then | |
echo "Attempting install of: $missing" | |
apt-get update | |
apt-get install -y $missing | |
fi | |
if [[ ! $(command -v docker) ]]; then | |
curl -sSL https://get.docker.com | sh | |
fi | |
requirements=("docker" "bash" "socat" "jq" "curl" "avahi-daemon" "dbus-daemon") | |
missing= | |
echo "Checking for all requirements..." | |
for cmd in ${requirements[@]}; do | |
package="$cmd" | |
[[ "$cmd" == "dbus-daemon" ]] && package="dbus" | |
[[ $(command -v "$cmd") ]] || missing="$missing$package " | |
done | |
if [[ -n "$missing" ]]; then | |
echo "Could not install requirements: $missing" | |
echo "Please install manually and run this script again." | |
exit 1 | |
else | |
echo "All requirements found!" | |
fi | |
echo "Installing Hass.io..." | |
curl -sL https://raw.githubusercontent.com/home-assistant/hassio-build/master/install/hassio_install | bash -s -- -m raspberrypi3 | |
echo | |
echo "Done." |
can anyone help me?
getting this
Installing Hass.io...
bash: line 1: 404:: command not found
Done.
can anyone help me?
getting this
Installing Hass.io...
bash: line 1: 404:: command not foundDone.
the install script is deprecated.
needs to be replaced with this:
curl -sL https://raw.githubusercontent.com/home-assistant/hassio-installer/master/hassio_install.sh | bash -s -- -m raspberrypi3
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
systemctl start hassio-supervisor.service