Accept standalone bashio

This commit is contained in:
Alexandre
2026-01-29 11:06:24 +01:00
committed by GitHub
parent fd8e5e0e15
commit f43020d85b
114 changed files with 977 additions and 531 deletions

View File

@@ -229,14 +229,17 @@ for files in "/etc/services.d" "/etc/cont-init.d"; do
if ! ls $files 1> /dev/null 2>&1; then continue; fi
# Bashio
if grep -q -rnw "$files/" -e 'bashio' && [ ! -f "/usr/bin/bashio" ]; then
if grep -q -rnw "$files/" -e 'bashio' && [ ! -f "/usr/bin/bashio.real" ]; then
[ "$VERBOSE" = true ] && echo "install bashio"
BASHIO_VERSION="latest"
mkdir -p /tmp/bashio
BASHIO_TAG="$(curl -f -L -s -S "https://api.github.com/repos/hassio-addons/bashio/releases/${BASHIO_VERSION}" | awk -F '\"' '/tag_name/{print $4; exit}')"
curl -f -L -s -S "https://github.com/hassio-addons/bashio/archive/${BASHIO_TAG}.tar.gz" | tar -xzf - --strip 1 -C /tmp/bashio
BASHIO_TAG="$(curl -fsSL "https://api.github.com/repos/hassio-addons/bashio/releases/${BASHIO_VERSION}" \
| awk -F '\"' '/tag_name/{print $4; exit}')"
curl -fsSL "https://github.com/hassio-addons/bashio/archive/${BASHIO_TAG}.tar.gz" \
| tar -xzf - --strip 1 -C /tmp/bashio
mv /tmp/bashio/lib /usr/lib/bashio
ln -s /usr/lib/bashio/bashio /usr/bin/bashio
mv /tmp/bashio/bashio /usr/bin/bashio.real
chmod +x /usr/bin/bashio.real
rm -rf /tmp/bashio
fi