From 2029e1796f6ae07dda7946daeaf7eebafe01b57c Mon Sep 17 00:00:00 2001 From: tommy Date: Sat, 4 Jan 2025 00:35:38 +0000 Subject: [PATCH] Update apps/home-assistant/Dockerfile --- apps/home-assistant/Dockerfile | 27 ++++++++++----------------- 1 file changed, 10 insertions(+), 17 deletions(-) diff --git a/apps/home-assistant/Dockerfile b/apps/home-assistant/Dockerfile index df31b36..bec3d9a 100644 --- a/apps/home-assistant/Dockerfile +++ b/apps/home-assistant/Dockerfile @@ -75,29 +75,22 @@ RUN \ libxslt-dev \ postgresql-dev \ unixodbc-dev \ - && \ - rm -rf /config/deps/orjson || true \ - && \ - pip install uv \ - && \ - pip install orjson --target /config/deps \ - && \ - curl -fsSL "https://github.com/home-assistant/core/archive/${VERSION}.tar.gz" \ + && rm -rf /config/deps/orjson || true \ + && pip install uv \ + && curl -fsSL "https://github.com/home-assistant/core/archive/${VERSION}.tar.gz" \ | tar xzf - -C /tmp --strip-components=1 \ - && \ - HOME_ASSISTANT_BASE=$(curl -fsSL "https://raw.githubusercontent.com/home-assistant/core/${VERSION}/build.yaml" | grep "amd64: " | cut -d ":" -f3) \ - && \ - uv pip install --only-binary=:all: --find-links "${HOMEASSISTANT_WHEELS}" \ + && HOME_ASSISTANT_BASE=$(curl -fsSL "https://raw.githubusercontent.com/home-assistant/core/${VERSION}/build.yaml" | grep "amd64: " | cut -d ":" -f3) \ + && uv pip install --only-binary=:all: --find-links "${HOMEASSISTANT_WHEELS}" \ --requirement "https://raw.githubusercontent.com/home-assistant/docker/${HOME_ASSISTANT_BASE}/requirements.txt" \ - && \ - uv pip install --only-binary=:all: --find-links "${HOMEASSISTANT_WHEELS}" \ + && uv pip install --only-binary=:all: --find-links "${HOMEASSISTANT_WHEELS}" \ --requirement /tmp/requirements_all.txt \ - && \ - uv pip install --only-binary=:all: --find-links "${HOMEASSISTANT_WHEELS}" \ + && uv pip install --only-binary=:all: --find-links "${HOMEASSISTANT_WHEELS}" \ homeassistant=="${VERSION}" \ && curl -L https://github.com/AlexxIT/go2rtc/releases/download/v1.9.8/go2rtc_linux_amd64 --output /bin/go2rtc \ && chmod +x /bin/go2rtc \ - && mkdir -p /config && chown nobody:nogroup -R /config \ + && mkdir -p /config \ + && uv pip install orjson --target /config/deps \ + && chown nobody:nogroup -R /config \ && apk del --purge .build-deps \ && rm -rf /root/.cache /root/.cargo /tmp/*