-
Notifications
You must be signed in to change notification settings - Fork 477
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WIP] Add homeassistant-supervisor
container to improve Home Assistant Voice Assistant stack onboarding on Jetson devices
#505
base: dev
Are you sure you want to change the base?
Conversation
…with twine upload
…rate package with twine upload
This is awesome @ms1design, good luck in your mission! 🙏 The crew from Seeed Studio would also probably be interested to help you with this if you didn't already show it to them. |
It's funny—I discussed it with Elaine, but back then, I advised against using supervisor because I found it too complicated to support or use. 🙈 Welcome to my world 😆 |
May 15, 2024 updateLogs: _hassio_supervisor_logs.txt
|
Wow, okay! This is awesome @ms1design ! Hopefully this makes things a lot easier for everyone 🙏 That docker run command 🤣 If making those |
@dusty-nv, I’m rolling hard on this docker run command too 😂 it's a huge roll forward 🤣 especially when we realise how complicated it is to port all HA repositories and integrate them together. I was trying to make it work with almost no changes to the host machine, which leaves us with one critical error regarding udev permissions, among many other warnings as shown in the previous screenshots. These are not the best results from a user perspective. I’m tempted to extend the jetson-containers API to support installation and uninstallation scripts for host machines, which would essentially make the Dockerfile unnecessary for this container. We can tackle that with a little reorganisation:
My ideal plan is for the user to issue just one command on the host machine, which will install HA Supervisor with all system dependencies and optionally the full Wyoming Voice Assistant pipeline from jetson-containers. This might take some time :) |
Sounds like a good plan @ms1design. Thank you for looking into this - that's okay if it takes time, I appreciate you wanting to go about it the right way that is easiest for users. My guess/hope is this will all come together nicely around the time we have the more advanced agents operating and hopefully the new AI API's defined by HA. I have been working with the Anyways, yea - your HA Supervisor repo could include jetson-containers as a submodule if that aids in the one-click/one-command scripted setup. Others in the group have been using jetson-containers as a submodule in their projects and that design seems to be working well for them. |
homeassistant-supervisor
Hi @dusty-nv 👋
To keep Home Assistant on Jetson project progressing, I'm revisiting the experiments with the Home Assistant Supervisor container. My aim is to simplify the onboarding process for Home Assistant and Wyoming add-ons on Jetson devices based on our experiences during the latest Jetson AI Research Group meeting.
While I'm not sure whether containerizing Supervisor and making it work with all its system dependencies is feasible, I'm willing to give it a shot. Below is what I tried yesterday and what should be done or fixed based on the
homeassistant-supervisor
logs.All questions and advice are warmly welcomed!
Updates:
May 8, 2024
Logs: _homeassistant-supervisor_logs.txt
homeassistant-supervisor
container.ciso8601
andpsutil-home-assistant
) to standalone, reusable containers in thesmart-home/dependencies
directory.homeassistant-supervisor
dependencyeudev
in thesmart-home/dependencies
directory.403
errors when fetching RAW files from GitHub injetson_containers/utils.js
. This was achieved by switching fromurllib.request
(which still usesHTTP/1.1
) to therequests
library, enabling the use ofHTTP/2
requests.jetson_containers/utils.py
:handle_json_request
,handle_text_request
,github_latest_tag
, andget_json_value_from_url
.config.py
.homeassistant-core
container'sbuild.sh
script.homeassistant-supervised
container.Quick Start
host
machine runningdocker
using sameuser
:docker-compose.yaml
exampleTODO
Based on
homeassistant-supervisor
logsinstall.sh
script forhost
machine if conterization is impossibleEnsure thathomeassistant-core
can detect thehomeassistant-supervisor
container and vice versahomeassistant-supervisor
container docker volumes & pathseudev
dependency container to support independent build & install stages to allowdpkg
uploadFix theSUPERVISOR_MACHINE
value to properly configurecoresys
(generic-aarch64
is used for now) to enable OTA updates:INFO (MainThread) [supervisor.bootstrap] Setting up coresys for machine: generic-aarch64
WARNING (MainThread) [supervisor.updater] Can't process version data: 'generic-aarch64'
~Fix thedocker
availability:WARNING (MainThread) [supervisor.resolution.evaluations.base] The configuration of Docker is not supported (more-info: https://www.home-assistant.io/more-info/unsupported/docker_configuration)
CRITICAL (MainThread) [supervisor.supervisor] Can't setup Supervisor Docker container!
WARNING (SyncWorker_0) [supervisor.docker.manager] Can't get None for cleanup
docker
deamon onhost
machine to support required method of logging (or find an easy way of doing that for users):WARNING (MainThread) [supervisor.resolution.evaluations.docker_configuration] Docker logging driver json-file is not supported!
AppArmor
(but where? in container or on host?):WARNING (MainThread) [supervisor.host.apparmor] AppArmor is not enabled on host
WARNING (MainThread) [supervisor.resolution.evaluations.base] AppArmor is required for Home Assistant. (more-info: https://www.home-assistant.io/more-info/unsupported/apparmor)
WARNING (MainThread) [supervisor.resolution.evaluations.base] Supervisor does not run in Privileged mode. (more-info: https://www.home-assistant.io/more-info/unsupported/privileged)
CRITICAL (MainThread) [supervisor.hardware.monitor] Not privileged to run udev monitor!
Sort out trusted content security:WARNING (MainThread) [supervisor.resolution.evaluations.base] System run with disabled trusted content security. (more-info: https://www.home-assistant.io/more-info/unsupported/content_trust)
WARNING (MainThread) [supervisor.security.module] Disabled content-trust, skip validation
Sort this out (could be because of useSUPERVISOR_DEV: 1
):0.00s - Debugger warning: It seems that frozen modules are being used, which may make the debugger miss breakpoints. Please pass -Xfrozen_modules=off to python to disable frozen modules. Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation.
Fix the missingcli
docker
plugin in container:INFO (MainThread) [supervisor.plugins.base] No cli plugin Docker image None found.
WARNING (MainThread) [supervisor.plugins.base] Error on installing cli plugin, retrying in 30sec
Unknown issue:INFO (MainThread) [supervisor.docker.interface] Found None versions: [<AwesomeVersion CalVer '22.04'>, <AwesomeVersion SpecialContainer 'latest'>, <AwesomeVersion SpecialContainer 'latest'>, <AwesomeVersion SpecialContainer 'latest'>, <AwesomeVersion SpecialContainer 'latest'>, <AwesomeVersion SemVer '2.19.4'>, <AwesomeVersion SpecialContainer 'latest'>]
docker-compose
example: