Supervisor in devcontainer not discovering local add-ons
See original GitHub issueDescribe the issue you are experiencing
I cloned a fresh copy of the addons-example repository. After fixing some permissions issues in the dev container found in #3969 I managed to get home assistant running in the container with the vscode task.
As the example repo comes with an example add-on I tried to find it in the add-on store. Unfortunately it doesn’t show up as a local add-on, even though I enabled advanced mode on my profile.
What type of installation are you running?
Home Assistant Supervised
Which operating system are you running on?
Other (e.g., Raspbian/Raspberry Pi OS/Fedora)
Steps to reproduce the issue
- Clone a fresh copy of the example add-ons repository:
git clone https://github.com/home-assistant/addons-example
- Open the directory in vscode but DO NOT open the window in the container as asked by the pop-up
- Add
sudo -u root -g root
to thepostStartCommand
property in.devcontainer.json
and to thecommand
property in.vscode/tasks.json
to get the container and home assistant running: 2.1. tasks.json"command": "sudo -u root -g root supervisor_run",
2.2. .devcontainer.json"postStartCommand": "sudo -u root -g root bash devcontainer_bootstrap",
- Now click on the option to open the window in the container and let it build
- Run the Home Assistant task in vscode to start it
- Setup home assistant
- Turn on advanced mode in your home assistant profile
- Go to the add-on store and check for updates
- No local add-on shows up
Anything in the Supervisor logs that might be useful for us?
22-10-27 11:48:10 INFO (MainThread) [supervisor.store.git] Update add-on https://github.com/hassio-addons/repository repository
22-10-27 11:48:10 INFO (MainThread) [supervisor.store.git] Update add-on https://github.com/esphome/home-assistant-addon repository
22-10-27 11:48:10 INFO (MainThread) [supervisor.store.git] Update add-on https://github.com/home-assistant/addons repository
22-10-27 11:48:12 INFO (MainThread) [supervisor.store] Loading add-ons from store: 68 all - 0 new - 0 remove
22-10-27 11:48:12 INFO (MainThread) [supervisor.store] Loading add-ons from store: 68 all - 0 new - 0 remove
System Health information
System Information
version | core-2022.12.0.dev20221027 |
---|---|
installation_type | Home Assistant Supervised |
dev | true |
hassio | true |
docker | true |
user | root |
virtualenv | false |
python_version | 3.10.5 |
os_name | Linux |
os_version | 5.10.88-0-virt |
arch | x86_64 |
timezone | UTC |
config_dir | /config |
Home Assistant Cloud
logged_in | false |
---|---|
can_reach_cert_server | ok |
can_reach_cloud_auth | ok |
can_reach_cloud | ok |
Home Assistant Supervisor
host_os | null |
---|---|
update_channel | dev |
supervisor_version | supervisor-2022.10.dev2702 |
agent_version | 1.2.2 |
docker_version | 20.10.18 |
disk_total | 58.8 GB |
disk_used | 29.9 GB |
healthy | true |
supported | failed to load: Unsupported |
supervisor_api | ok |
version_api | ok |
installed_addons |
Dashboards
dashboards | 1 |
---|---|
resources | 0 |
mode | auto-gen |
Recorder
oldest_recorder_run | 27 October 2022, 09:28 |
---|---|
current_recorder_run | 27 October 2022, 11:28 |
estimated_db_size | 0.18 MiB |
database_engine | sqlite |
database_version | 3.38.5 |
Supervisor diagnostics
config_entry-hassio-c72303453e26912dc840481d9c82d4f2.json.txt
Additional information
$ docker --version
Docker version 20.10.20, build 9fdeb9c3de
$ docker info
Client:
Context: colima
Debug Mode: false
Server:
Containers: 100
Running: 3
Paused: 0
Stopped: 97
Images: 98
Server Version: 20.10.11
Storage Driver: overlay2
Backing Filesystem: extfs
Supports d_type: true
Native Overlay Diff: true
userxattr: false
Logging Driver: json-file
Cgroup Driver: cgroupfs
Cgroup Version: 1
Plugins:
Volume: local
Network: bridge host ipvlan macvlan null overlay
Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
Swarm: inactive
Runtimes: io.containerd.runc.v2 io.containerd.runtime.v1.linux runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 1e5ef943eb76627a6d3b6de8cd1ef6537f393a71
runc version: b9ee9c6314599f1b4a7f497e1f1f856fe433d3b7
init version:
Security Options:
seccomp
Profile: default
Kernel Version: 5.10.88-0-virt
Operating System: Alpine Linux v3.14
OSType: linux
Architecture: x86_64
CPUs: 4
Total Memory: 3.844GiB
Name: colima
ID: 43LX:AFMI:J2G2:HMU3:4XGB:EQL2:RZ4F:CTAT:BJZ6:DDBE:SIRI:JVFG
Docker Root Dir: /var/lib/docker
Debug Mode: false
Registry: https://index.docker.io/v1/
Labels:
Experimental: false
Insecure Registries:
127.0.0.0/8
Live Restore Enabled: false
Issue Analytics
- State:
- Created a year ago
- Reactions:1
- Comments:6 (1 by maintainers)
Top Results From Across the Web
Problems setting up addons devcontainer - Development
I have been having issues trying to configure the devcontainer for testing a custom addon following the steps outlined here.
Read more >Developing inside a Container - Visual Studio Code
A devcontainer.json file in your project tells VS Code how to access (or create) a ... You do not even need to have...
Read more >Reproducible Development with Devcontainers - InfoQ
I build a brand new set of container configuration files, working from the project setup instructions rather than from any existing Dockerfiles.
Read more >Code From Anywhere: Dev Containers and Github Codespaces
... want to write a simple blog entry were getting stuck trying to get the blog working locally. Not only did Dev Containers...
Read more >Install Home Assistant on Linux/Docker with Supervisor (how ...
Getting add-ons and snapshots on Home Assistant without using Home Assistant OS can be tricky, however today I will show you how to...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I tried it just now, unfortunately it doesn’t help. Still no local add-ons show up
There hasn’t been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.