I am having trouble setting up the auto start feature. I type hass --script macos install and I get "No such file or directory: ‘/Users/…/Library/LaunchAgents/org.haomeassistant.plist’ "
You could use a cron-automation. Use crontab -e
in the terminal and add something like @reboot /usr/local/bin/hass
.
Use the right path to your executable. Since cron has a limited set of enviroment variables you maybe need to add the pythpath manual. I don’t know exactly if you would need it and where it is. I run hass on lubuntu and i need to add the following before the cronjob PYTHONPATH=/home/YOURUSERNAME/.local/lib/python3.5/site-packages/
Good luck. Took me a while to get it working too.
I ran into the same issue. For me, I didn’t have anything set to launch at login for the user account I was using, so there was no “LaunchAgents” directory created in the ~/Library directory for my user.
How I fixed it on my machine:
Open terminal (copy and past the code below)
cd ~/Library/
mkdir LaunchAgents
hass --script macos install
done
Hope that helps!
-Eric
I also have a problem getting the Home Assistant LaunchAgent to work on macOS.
$ hass --script macos install
Home Assistant has been installed. Open it here: http://localhost:8123
Could not find domain for
$ ls -ltr ~/Library/LaunchAgents/
total 8
-rw-r--r-- 1 hass staff 831 Aug 3 12:41 org.homeassistant.plist
$ launchctl list
Does not list org.homeassistant.
What does "Could not find domain for " actually mean?
Does it have to do with the launchctl load
command being deprecated, and replaced by launchctl bootstrap user/<uid>
?
Is it because I’m logged in using SSH or login
on Terminal from another user?
I experienced with this problem during , during modifying the kernel resource of macOS for Home Assistant.
Just by login in remote desktop, and restart the Hass via its local terminal, this problem goes away.
worth trying, NO guarantee.