diff --git a/apps/home-assistant/entrypoint.sh b/apps/home-assistant/entrypoint.sh index c9a1771..d1016b5 100644 --- a/apps/home-assistant/entrypoint.sh +++ b/apps/home-assistant/entrypoint.sh @@ -1,11 +1,22 @@ #!/usr/bin/env bash #shellcheck disable=SC2086 +# Create /config/tmp if it doesn't exist and ensure proper permissions +if [[ ! -d /config/tmp ]]; then + mkdir -p /config/tmp + chmod 1777 /config/tmp +fi + +# Set TMPDIR environment variable for uv and other temporary file operations +export TMPDIR="/config/tmp" + +# Ensure HACS installation if requested if [[ "${HOME_ASSISTANT__HACS_INSTALL}" == "true" ]]; then curl -sfSL https://get.hacs.xyz | bash - fi +# Execute Home Assistant with the provided arguments exec \ /usr/local/bin/hass \ --config /config \ - "$@" \ No newline at end of file + "$@"