Hassbian install script for homebridge

Hi. I’ve made an install script for homebridge on hassbian, based on the ones by @Landrash in the hassbian-scripts folder in hassbian.
I haven’t fully tested it, so it’s a work in progress, but I thought if people wanted to try it, improve it, then we could make it part of the next hassbian image… what do you think @Landrash?


This looks good. :fireworks:
Jump in the gitter channel and lets get this in among the scripts shipped with Hassbian.

Maby a stupid question but how do I run this?

i placed it into a shell script and then gave the script permissions to run, and managed to install it that way. After a lot of googling i have managed to get it running on my hassbian image. It has taken me the best part of 3 days to get it working, maybe the author can provide some instructions, if not i will try and document my process i did over the weekend, but i am still a noob when it comes to this sort of thing so i can’t promise it’ll be great.

I haven’t had much chance to test this on a fresh install yet. Other than putting it into a .sh file with x permissions, what else did you need to do (brief is fine)?

Any updates on this project? I used to run Homebridge on my Mint build but now I want it running with Homeassistant on Hassbian.

I see no one has left any instructions for non-power users or comments on whether it’s working correctly or not.

Happy to provide updates if you can provide some guide for what you need to know and where you get stuck.
It’s a Linux script, so you download the text (click Raw in the GitHub interface) to a file with that name.
At the Linux command line, you might have to give it execute permission:
chmod u+x install_homebridge.sh

Then run it from the directory it’s in:

I see @Landrash has forked it, so perhaps he has some updates on how it went and if his version is different/improved…?

Thanks for the reply as a noob I wasn’t sure how to run the script, so I ran each piece manually and got everything working.


Time has been an issue since I’m buying a house.
I currently have a “working” version but I prefer not releasing a new version of Hassbian before we get the Stretch base working :slight_smile:

I used the Hassbian install script to install Homebridge integration. But no matter what I do (delete the persistent and accessoires folder and alter the username in the bridge section of config.json), Homebridge still doesn’t appear in the Home app of Apple.
What am I’m doing wrong? Homekit Server is starting just fine and it receives all kind of events from Home Assistant.

If it’s working and receiving events, as I assume you see in the log, it probably won’t be an issue with this script…
Have you added it as a device in your Apple product (iPhone or similar?) Did you scan or enter the code? It doesn’t just appear automatically. (This should be in the HomeKit docs.)

I assume the script is working correctly. As I try to add Homebridge it just doesn’t appear in Home or any other app like Elgato Eve. So I don’t even come to the scanning or entering the code part. That’s the problem. It looks as if the Pi3 is on another network than my iPhone…

Hi, THANK YOU @lindsayward!
your script helped me very much!

I finally managed to set everything up and running… I’m so happy! :sweat_smile:
But I didn’t run it as is, I made some modifications…

  • Setting homebridge back to default location.
  • Added pm2 and let it manage the autorun.
  • Add a console prompts to ask for the Host ip and password so to make the process more noob friendly.
  • some minor formatting changes.

here is what I did so far

I even mannaged to setup smarththings with mosquitto-mqtt
but I haven’t add it to this script… I’m thinking of making a separate script for all my setup.
BIG but… I’m very much a noob… proceed with caution… :wink:

Gil. :slight_smile:

1 Like

Hi all!

I Have made a step by step guide to implement smartthings and homebridge…

Gil. :slight_smile:

1 Like

It has worked for me in the past, so maybe it is worth trying:

Edit file ‘/etc/avahi/avahi-daemon.conf’ by finding line with ‘use-ipv6=’.

If it says yes or is not present, make sure you end up with ‘use-ipv6=no’ (should be under server tag). Restart your homebridge service or even better your Pi, and then try again.

In the past, this has solved my issues of not being able to add Homebridge as accessory in Homekit.

Oké @pplucky. Thanks I’ll give it a try.

Does making a device (raspberry 2) wiht Hass.io and Homebridge installed, helps you to Remote Control your Homekit devices without the need of Apple TV?

Install script works great! Hope it will be included in Hassbian soon.

I have got the homebridge up and running and working, but how do I make it start automatic in the background when I start my rPi?

Does it not automatically start as a daemon?
Have you restarted and checked if it’s running with ps?