Open banan77 opened 3 years ago
Hello @banan77,
Thank you for taking a look at this project. I understand that you are having trouble getting it to work in your environment with the Raspberry Pi.
This add-on was intentionally limited from being installed in those environments, because I could not verify that it worked.
I removed that limitation in #1. I would really appreciate it if you could try it again. Thank you!
Hi, thank you for quick response. Now the addon appears as available for installation (Install button is now blue while before it was greyed out) but after trying to install get another error: "Failed to install add-on The command '/bin/ash -o pipefail -c set -x && apk add --no-cache --virtual .build-dependencies build-base linux-headers libusb-dev git python3 && python3 -m ensurepip' returned a non-zero code: 6"
Thanks for the validation. It turns out it's not as easy as I thought, so please give me some more time to fix it. I understand that running on a Raspberry Pi is a common use case, so I'm hoping to fix this issue, although it may take some time. Thank you!
Unfortunately, I could not reproduce the issue. Don't you see any other logs? I believe the logs can be fetched from the add-on page inside the Supervisor panel in Home Assistant.
$ uname -a
Linux ip-172-31-31-206 5.4.0-1045-aws #47-Ubuntu SMP Tue Apr 13 07:04:23 UTC 2021 aarch64 aarch64 aarch64 GNU/Linux
$ docker build --build-arg BUILD_FROM="homeassistant/aarch64-base:latest" -t local/uhubctl .
Sending build context to Docker daemon 18.94kB
Step 1/9 : ARG BUILD_FROM
Step 2/9 : FROM ${BUILD_FROM}
latest: Pulling from homeassistant/aarch64-base
552d1f2373af: Pull complete
5b0203384f61: Pull complete
d48dc279c802: Pull complete
Digest: sha256:f006faab22ff450b0dd1d2c0fdbd424b76e38ec8e903aa31490abe5a628c61c2
Status: Downloaded newer image for homeassistant/aarch64-base:latest
---> fc4c367ab17d
Step 3/9 : RUN set -x && apk add --no-cache --virtual .build-dependencies build-base linux-headers libusb-dev git python3 && python3 -m ensurepip
---> Running in 92013c9495d8
+ apk add --no-cache --virtual .build-dependencies build-base linux-headers libusb-dev git python3
fetch https://dl-cdn.alpinelinux.org/alpine/v3.14/main/aarch64/APKINDEX.tar.gz
fetch https://dl-cdn.alpinelinux.org/alpine/v3.14/community/aarch64/APKINDEX.tar.gz
(1/34) Installing libgcc (10.3.1_git20210424-r2)
(2/34) Installing libstdc++ (10.3.1_git20210424-r2)
(3/34) Installing binutils (2.35.2-r2)
(4/34) Installing libmagic (5.40-r1)
(5/34) Installing file (5.40-r1)
(6/34) Installing libgomp (10.3.1_git20210424-r2)
(7/34) Installing libatomic (10.3.1_git20210424-r2)
(8/34) Installing libgphobos (10.3.1_git20210424-r2)
(9/34) Installing gmp (6.2.1-r0)
(10/34) Installing isl22 (0.22-r0)
(11/34) Installing mpfr4 (4.1.0-r0)
(12/34) Installing mpc1 (1.2.1-r0)
(13/34) Installing gcc (10.3.1_git20210424-r2)
(14/34) Installing musl-dev (1.2.2-r3)
(15/34) Installing libc-dev (0.7.2-r3)
(16/34) Installing g++ (10.3.1_git20210424-r2)
(17/34) Installing make (4.3-r0)
(18/34) Installing fortify-headers (1.1-r1)
(19/34) Installing patch (2.7.6-r7)
(20/34) Installing build-base (0.5-r2)
(21/34) Installing linux-headers (5.10.41-r0)
(22/34) Installing libusb (1.0.24-r2)
(23/34) Installing pkgconf (1.7.4-r0)
(24/34) Installing libusb-dev (1.0.24-r2)
(25/34) Installing expat (2.4.1-r0)
(26/34) Installing pcre2 (10.36-r0)
(27/34) Installing git (2.32.0-r0)
(28/34) Installing libbz2 (1.0.8-r1)
(29/34) Installing libffi (3.3-r2)
(30/34) Installing gdbm (1.19-r0)
(31/34) Installing mpdecimal (2.5.1-r1)
(32/34) Installing sqlite-libs (3.35.5-r0)
(33/34) Installing python3 (3.9.5-r1)
(34/34) Installing .build-dependencies (20210927.014440)
Executing busybox-1.33.1-r3.trigger
OK: 277 MiB in 73 packages
+ python3 -m ensurepip
Looking in links: /tmp/tmpvmfutx9l
Processing /tmp/tmpvmfutx9l/setuptools-56.0.0-py3-none-any.whl
Processing /tmp/tmpvmfutx9l/pip-21.1.1-py3-none-any.whl
Installing collected packages: setuptools, pip
Successfully installed pip-21.1.1 setuptools-56.0.0
WARNING: Running pip as root will break packages and permissions. You should install packages reliably by using venv: https://pip.pypa.io/warnings/venv
Removing intermediate container 92013c9495d8
---> f549a4c18af7
Step 4/9 : RUN git clone https://github.com/mvp/uhubctl.git /tmp/uhubctl && cd /tmp/uhubctl && make && make install
---> Running in 39b0665951f0
Cloning into '/tmp/uhubctl'...
cc -g -O0 -Wall -Wextra -std=c99 -pedantic -DPROGRAM_VERSION=\"2.4.0-16-g37f494ff\" -I/usr/include/libusb-1.0 uhubctl.c -o uhubctl -Wl,-zrelro,-znow -lusb-1.0
install -m 755 -d /usr/sbin
install -m 755 uhubctl /usr/sbin
Removing intermediate container 39b0665951f0
---> e72e2c4347cc
Step 5/9 : COPY . /app
---> cafcbd9b4f26
Step 6/9 : WORKDIR /app
---> Running in 91f5258e1fd8
Removing intermediate container 91f5258e1fd8
---> b0a7102f00b9
Step 7/9 : RUN pip3 install -r requirements.txt
---> Running in 4ed44abbab3c
Collecting paho-mqtt==1.5.1
Downloading paho-mqtt-1.5.1.tar.gz (101 kB)
Using legacy 'setup.py install' for paho-mqtt, since package 'wheel' is not installed.
Installing collected packages: paho-mqtt
Running setup.py install for paho-mqtt: started
Running setup.py install for paho-mqtt: finished with status 'done'
Successfully installed paho-mqtt-1.5.1
WARNING: Running pip as root will break packages and permissions. You should install packages reliably by using venv: https://pip.pypa.io/warnings/venv
WARNING: You are using pip version 21.1.1; however, version 21.2.4 is available.
You should consider upgrading via the '/usr/bin/python3 -m pip install --upgrade pip' command.
Removing intermediate container 4ed44abbab3c
---> 5c565bae8240
Step 8/9 : RUN chmod a+x run.sh
---> Running in 11d04db5a076
Removing intermediate container 11d04db5a076
---> f70b52d955a7
Step 9/9 : CMD ["/app/run.sh"]
---> Running in 941bbe20e1c6
Removing intermediate container 941bbe20e1c6
---> d35c83865ce1
Successfully built d35c83865ce1
Successfully tagged local/uhubctl:latest
Hi, I have installed uhubctl on rpi via console (not in docker) and it seems to be working (only when all ports are turned off - this is know for rpi4). The issue is when trying to install uhubctl as addon to homeassistant (in docker)
that's what I could find in HA Supervisor log:
21-09-27 11:40:52 INFO (SyncWorker_0) [supervisor.docker.addon] Starting build for 347b947f/armv7-addon-uhubctl:0.0.61 21-09-27 11:40:55 ERROR (SyncWorker_0) [supervisor.docker.addon] Can't build 347b947f/armv7-addon-uhubctl:0.0.61: The command '/bin/ash -o pipefail -c set -x && apk add --no-cache --virtual .build-dependencies build-base linux-headers libusb-dev git python3 && python3 -m ensurepip' returned a non-zero code: 6 21-09-27 11:40:55 ERROR (SyncWorker_0) [supervisor.docker.addon] Build log: Step 1/14 : ARG BUILD_FROM Step 2/14 : FROM ${BUILD_FROM} ---> a6b4abf955c9 Step 3/14 : RUN set -x && apk add --no-cache --virtual .build-dependencies build-base linux-headers libusb-dev git python3 && python3 -m ensurepip ---> Running in 559e91ba705b
fetch https://dl-cdn.alpinelinux.org/alpine/v3.14/main/armv7/APKINDEX.tar.gz fetch https://dl-cdn.alpinelinux.org/alpine/v3.14/community/armv7/APKINDEX.tar.gz WARNING: Ignoring https://dl-cdn.alpinelinux.org/alpine/v3.14/main: temporary error (try again later)
WARNING: Ignoring https://dl-cdn.alpinelinux.org/alpine/v3.14/community: temporary error (try again later)
ERROR: unable to select packages:
build-base (no such package): required by: .build-dependencies-19700101.000000[build-base] linux-headers (no such package): required by: .build-dependencies-19700101.000000[linux-headers] libusb-dev (no such package): required by: .build-dependencies-19700101.000000[libusb-dev] git (no such package): required by: .build-dependencies-19700101.000000[git] python3 (no such package): required by: .build-dependencies-19700101.000000[python3] Removing intermediate container 559e91ba705b
After years, it's still not working I think? Im running HomeAssistant on a Raspberry Pi 3.
Error message: De installatie van de add-on is mislukt The command '/bin/ash -o pipefail -c set -x && apk add --no-cache --virtual .build-dependencies build-base linux-headers libusb-dev git python3 && python3 -m ensurepip' returned a non-zero code: 1
HomeAssistant log details: Logger: homeassistant.components.hassio Source: components/hassio/websocket_api.py:138 Integration: Home Assistant Supervisor (documentation, issues) First occurred: 15:46:10 (1 occurrences) Last logged: 15:46:10
Failed to to call /addons/347b947f_uhubctl/install - The command '/bin/ash -o pipefail -c set -x && apk add --no-cache --virtual .build-dependencies build-base linux-headers libusb-dev git python3 && python3 -m ensurepip' returned a non-zero code: 1
Hi, tried to install the addon but get: "Failed to install add-on Add-on cf175d6d_uhubctl not supported on that platform" My setup: Raspberry Pi 4B (Raspberry Pi OS) Home Assistant 2021.9.6 Supervised installed in Docker
Am I missing something or my setup is indeed not supported? Regards, Marcin