diff --git a/.templates/00-banner.sh b/.templates/00-banner.sh index 8d5d50e03..2bf4aa8fb 100755 --- a/.templates/00-banner.sh +++ b/.templates/00-banner.sh @@ -1,85 +1,50 @@ #!/usr/bin/with-contenv bashio # shellcheck shell=bash disable=SC2016 set -e -# ============================================================================== -# Displays a simple add-on banner on startup -# ============================================================================== -if ! bashio::supervisor.ping 2> /dev/null; then - # Degraded mode if no homeassistant - bashio::log.blue \ - '-----------------------------------------------------------' - bashio::log.blue "Starting addon without HA support" +# ====================================================================== +# Banner +# ====================================================================== + +if ! bashio::supervisor.ping 2>/dev/null; then + bashio::log.blue '-----------------------------------------------------------' + bashio::log.blue "Starting addon in standalone mode (no Supervisor)" bashio::log.blue "Version : ${BUILD_VERSION:-1.0}" - bashio::log.blue "Please use Docker Compose for env variables" - bashio::log.blue \ - '-----------------------------------------------------------' - # Use environment variables instead of addon options - echo "... convert scripts to use environment variables instead of addon options" - while IFS= read -r scripts; do - [[ "$scripts" == *"00-banner.sh"* ]] && continue - sed -i -e 's/bashio::config.has_value[[:space:]]*["'"'"']\([^"'"'"']*\)["'"'"']/[ ! -z "${\1:-}" ]/g' \ - -e 's/bashio::config.true[[:space:]]*["'"'"']\([^"'"'"']*\)["'"'"']/[ ! -z "${\1:-}" ] \&\& [ "${\1:-}" = "true" ]/g' \ - -e 's/\$(bashio::config[[:space:]]*["'"'"']\([^"'"'"']*\)["'"'"'])/${\1:-}/g' \ - -e 's/\$(bashio::addon.port[[:space:]]*["'"'"']\([0-9]*\)["'"'"'])/${\1:-}/g' \ - -e 's/bashio::config.require.ssl/true/g' \ - -e 's/\$(bashio::addon.ingress_port)/""/g' \ - -e 's/\$(bashio::addon.ingress_entry)/""/g' \ - -e 's/\$(bashio::addon.ip_address)/""/g' "$scripts" - done < <(grep -srl "bashio" /etc/cont-init.d /custom-services.d /etc/services.d /etc/s6-overlay) - exit 0 -fi - -bashio::log.blue \ - '-----------------------------------------------------------' -bashio::log.blue " Add-on: $(bashio::addon.name)" -bashio::log.blue " $(bashio::addon.description)" -bashio::log.blue \ - '-----------------------------------------------------------' - -bashio::log.blue " Add-on version: $(bashio::addon.version)" -if bashio::var.true "$(bashio::addon.update_available)"; then - bashio::log.magenta ' There is an update available for this add-on!' - bashio::log.magenta \ - " Latest add-on version: $(bashio::addon.version_latest)" - bashio::log.magenta ' Please consider upgrading as soon as possible.' + bashio::log.blue "Config source: ENV + /data/options.json" + bashio::log.blue '-----------------------------------------------------------' else - bashio::log.green ' You are running the latest version of this add-on.' + bashio::log.blue '-----------------------------------------------------------' + bashio::log.blue " Add-on: $(bashio::addon.name)" + bashio::log.blue " $(bashio::addon.description)" + bashio::log.blue '-----------------------------------------------------------' + + bashio::log.blue " Add-on version: $(bashio::addon.version)" + if bashio::var.true "$(bashio::addon.update_available)"; then + bashio::log.magenta " There is an update available!" + bashio::log.magenta " Latest version: $(bashio::addon.version_latest)" + else + bashio::log.green " You are running the latest version." + fi + + bashio::log.blue " System: $(bashio::info.operating_system)" + bashio::log.blue " Architecture: $(bashio::info.arch) / $(bashio::info.machine)" + bashio::log.blue " Home Assistant Core: $(bashio::info.homeassistant)" + bashio::log.blue " Home Assistant Supervisor: $(bashio::info.supervisor)" fi -bashio::log.blue " System: $(bashio::info.operating_system)" -bashio::log.blue " Architecture: $(bashio::info.arch) / $(bashio::info.machine)" -bashio::log.blue " Home Assistant Core: $(bashio::info.homeassistant)" -bashio::log.blue " Home Assistant Supervisor: $(bashio::info.supervisor)" +bashio::log.blue '-----------------------------------------------------------' +bashio::log.green ' Provided by: https://github.com/alexbelgium/hassio-addons ' +bashio::log.blue '-----------------------------------------------------------' -bashio::log.blue \ - '-----------------------------------------------------------' -bashio::log.blue \ - ' Please, share the above information when looking for help' -bashio::log.blue \ - ' or support in, e.g., GitHub, forums' -bashio::log.blue \ - '-----------------------------------------------------------' -bashio::log.green \ - ' Provided by: https://github.com/alexbelgium/hassio-addons ' -bashio::log.blue \ - '-----------------------------------------------------------' +# ====================================================================== +# UID/GID logic stays unchanged +# ====================================================================== -# ============================================================================== -# Global actions for all addons -# ============================================================================== -if bashio::config.has_value "PUID" && bashio::config.has_value "PGID" && id abc &> /dev/null; then - bashio::log.green ' Defining permissions for main user : ' +if bashio::config.has_value "PUID" && bashio::config.has_value "PGID" && id abc &>/dev/null; then PUID="$(bashio::config "PUID")" PGID="$(bashio::config "PGID")" usermod -o -u "$PUID" abc groupmod -o -g "$PGID" abc - bashio::log.blue "User UID: $(id -u abc)" - bashio::log.blue "User GID: $(id -g abc)" - - bashio::log.blue \ - '-----------------------------------------------------------' fi -# Clean bashrc file safely -if [ -f ~/.bashrc ]; then : > ~/.bashrc; fi +[ -f ~/.bashrc ] && : > ~/.bashrc diff --git a/.templates/bashio-routeur.sh b/.templates/bashio-routeur.sh new file mode 100644 index 000000000..337e48f62 --- /dev/null +++ b/.templates/bashio-routeur.sh @@ -0,0 +1,65 @@ +#!/usr/bin/env bash +set -euo pipefail + +REAL_BASHIO="/usr/bin/bashio.real" +if [ -x "/usr/bin/bashio" ] && [ ! -x "$REAL_BASHIO" ]; then + REAL_BASHIO="/usr/bin/bashio" +fi + +# ---- Supervisor detection ---- + +if [ -x "$REAL_BASHIO" ]; then + # Fast HA detection (s6) + if [ -S /run/s6/services/supervisor ]; then + exec "$REAL_BASHIO" "$@" + fi + + # Fallback ping detection (DNS/API) + if "$REAL_BASHIO" supervisor ping >/dev/null 2>&1; then + exec "$REAL_BASHIO" "$@" + fi +fi + +# ---- Standalone fallback ---- +# shellcheck disable=SC1091 +. /usr/local/lib/bashio-standalone.sh + +cmd="${1:-}"; shift || true + +case "$cmd" in + config) + bashio::config "$@" + ;; + log) + level="${1:-info}" + shift || true + fn="bashio::log.${level}" + if declare -F "$fn" >/dev/null 2>&1; then + "$fn" "$@" + else + bashio::log.info "$@" + fi + ;; + addon) + sub="${1:-}" + shift || true + "bashio::addon.${sub}" "$@" || true + ;; + info) + sub="${1:-}" + shift || true + "bashio::info.${sub}" "$@" || true + ;; + services) + bashio::services "$@" + ;; + supervisor) + sub="${1:-}" + shift || true + "bashio::supervisor.${sub}" "$@" || true + ;; + *) + echo "bashio router: unsupported command: $cmd" >&2 + exit 1 + ;; +esac diff --git a/.templates/bashio-standalone.sh b/.templates/bashio-standalone.sh index ff4da02b9..0986c162a 100755 --- a/.templates/bashio-standalone.sh +++ b/.templates/bashio-standalone.sh @@ -1,22 +1,26 @@ # /usr/local/lib/bashio-standalone.sh # shellcheck shell=bash # Minimal bashio compatibility layer for running Home Assistant add-ons -# as standalone containers (no Supervisor). It overrides common bashio::* -# functions to source config from ENV (and optionally a JSON file). -# Load it conditionally in your entry script when supervisor isn't reachable. +# in standalone containers (no Supervisor). -# -------- internals ---------------------------------------------------------- +# ----------------------------------------------------------------------------- +# Defaults +# ----------------------------------------------------------------------------- -# Whether to emit ANSI colors (disabled if not a TTY) -if [ -t 1 ]; then - _BASHIO_COLOR=1 -else - _BASHIO_COLOR=0 -fi +: "${STANDALONE_OPTIONS_JSON:=/data/options.json}" +: "${BASHIO_CACHE_DIR:=/tmp/.bashio}" + +# ----------------------------------------------------------------------------- +# Color handling +# ----------------------------------------------------------------------------- + +_BASHIO_COLOR=1 +[ ! -t 1 ] && _BASHIO_COLOR=0 +[ -n "${NO_COLOR:-}" ] && _BASHIO_COLOR=0 +[ "${TERM:-}" = "dumb" ] && _BASHIO_COLOR=0 _bashio_color() { - # $1=name; returns ANSI sequence or empty - if [ "$_BASHIO_COLOR" != "1" ]; then return 0; fi + [ "$_BASHIO_COLOR" = "1" ] || return 0 case "$1" in blue) printf '\033[34m' ;; green) printf '\033[32m' ;; @@ -28,54 +32,43 @@ _bashio_color() { } _bashio_log() { - # $1=color name, $2...=msg - local c="$1" - shift - local pre - pre="$(_bashio_color "$c")" - local rst - rst="$(_bashio_color reset)" - printf '%s%s%s\n' "$pre" "$*" "$rst" + local c="$1"; shift + printf '%s%s%s\n' "$(_bashio_color "$c")" "$*" "$(_bashio_color reset)" } -# Optional JSON options source (single flat object or nested). -# Set STANDALONE_OPTIONS_JSON to a path (e.g., /data/options.json). -# If jq is present, keys can be fetched as .key or .nested.key +# ----------------------------------------------------------------------------- +# JSON access (jq optional) +# ----------------------------------------------------------------------------- + _bashio_json_get() { - # $1=key (dot.notation). echoes value or empty; returns 0 always - local key="${1:-}" - local file="${STANDALONE_OPTIONS_JSON:-}" - if [ -z "$file" ] || [ ! -f "$file" ] || ! command -v jq > /dev/null 2>&1; then - return 0 - fi - # jq -r returns "null" for missing; convert to empty - local val - val="$(jq -er --arg k "$key" '. as $r | getpath(($k|split("."))) // empty' "$file" 2> /dev/null || true)" - [ "$val" = "null" ] && val="" - printf '%s' "$val" + local key="$1" file="$STANDALONE_OPTIONS_JSON" + [ -f "$file" ] || return 0 + command -v jq >/dev/null 2>&1 || return 0 + + jq -er --arg k "$key" ' + getpath(($k|split("."))) // empty + ' "$file" 2>/dev/null || true } -# Map a bashio "key" to an env var name. -# Order tried: -# 1) exact as-is -# 2) uppercase exact -# 3) dot->underscore, dash->underscore (upper & lower) -# 4) with prefixes: CFG_, CONFIG_, ADDON_, OPTION_, OPT_ +# ----------------------------------------------------------------------------- +# ENV mapping helper +# ----------------------------------------------------------------------------- + _bashio_env_get() { - # $1=key - local key="${1:-}" + local key="$1" [ -z "$key" ] && return 0 - local variants=() - variants+=("$key") - variants+=("$(printf '%s' "$key" | tr '[:lower:]' '[:upper:]')") - variants+=("$(printf '%s' "$key" | tr '.' '_' | tr '-' '_')") - variants+=("$(printf '%s' "$key" | tr '.' '_' | tr '-' '_' | tr '[:lower:]' '[:upper:]')") - - local prefixes=("" - "CFG_" "CONFIG_" "ADDON_" "OPTION_" "OPT_") - local v p name + local variants=( + "$key" + "${key^^}" + "${key//./_}" + "${key//./_}" + ) + variants+=("${variants[2]^^}") + + local prefixes=("" "CFG_" "CONFIG_" "ADDON_" "OPTION_" "OPT_") + for v in "${variants[@]}"; do for p in "${prefixes[@]}"; do name="${p}${v}" @@ -87,358 +80,169 @@ _bashio_env_get() { done } -# Helper: true/false parsing +# ----------------------------------------------------------------------------- +# Boolean parsing +# ----------------------------------------------------------------------------- + _bashio_is_true() { - # $1=value case "${1:-}" in - 1 | true | TRUE | yes | YES | on | On) return 0 ;; + 1|true|TRUE|yes|YES|on|ON) return 0 ;; *) return 1 ;; esac } -# Net wait using /dev/tcp (POSIX bash) with a timeout -_bashio_tcp_wait() { - # $1=host $2=port $3=timeout(s, default 30) - local host="$1" port="$2" to="${3:-30}" - local start now - start="$(date +%s)" - while :; do - if exec 3<> "/dev/tcp/${host}/${port}" 2> /dev/null; then - exec 3>&- 3<&- - return 0 - fi - now="$(date +%s)" - if [ $((now - start)) -ge "$to" ]; then - return 1 - fi - sleep 1 - done -} +# ----------------------------------------------------------------------------- +# Logging API +# ----------------------------------------------------------------------------- -# -------- logs --------------------------------------------------------------- - -bashio::log.blue() { _bashio_log blue "$*"; } -bashio::log.green() { _bashio_log green "$*"; } -bashio::log.yellow() { _bashio_log yellow "$*"; } -bashio::log.red() { _bashio_log red "$*"; } +bashio::log.blue() { _bashio_log blue "$*"; } +bashio::log.green() { _bashio_log green "$*"; } +bashio::log.yellow() { _bashio_log yellow "$*"; } +bashio::log.red() { _bashio_log red "$*"; } bashio::log.magenta() { _bashio_log magenta "$*"; } -# compatibility aliases often used -bashio::log.info() { bashio::log.blue "$@"; } +bashio::log.info() { bashio::log.blue "$@"; } bashio::log.warning() { bashio::log.yellow "$@"; } -bashio::log.error() { bashio::log.red "$@"; } -bashio::log.debug() { printf '%s\n' "$*"; } +bashio::log.error() { bashio::log.red "$@"; } +bashio::log.debug() { printf '%s\n' "$*"; } -# -------- supervisor & addon meta ------------------------------------------- +# ----------------------------------------------------------------------------- +# Supervisor shim +# ----------------------------------------------------------------------------- -# In standalone, "ping" always fails unless forced bashio::supervisor.ping() { - if _bashio_is_true "${STANDALONE_FORCE_SUPERVISOR_PING:-}"; then - return 0 - fi + _bashio_is_true "${STANDALONE_FORCE_SUPERVISOR_PING:-}" && return 0 return 1 } -# Add-on metadata (use env or sensible defaults) -bashio::addon.name() { printf '%s' "${ADDON_NAME:-Standalone container}"; } -bashio::addon.description() { printf '%s' "${ADDON_DESCRIPTION:-Running without Home Assistant Supervisor}"; } -bashio::addon.version() { printf '%s' "${BUILD_VERSION:-1.0}"; } -bashio::addon.version_latest() { printf '%s' "${ADDON_VERSION_LATEST:-${BUILD_VERSION:-1.0}}"; } -bashio::addon.update_available() { - if [ "${ADDON_VERSION_LATEST:-}" != "" ] && [ "${ADDON_VERSION_LATEST:-}" != "${BUILD_VERSION:-}" ]; then - printf '%s' "true" - return 0 - fi - printf '%s' "false" -} -bashio::addon.ingress_port() { printf '%s' "${ADDON_INGRESS_PORT:-}"; } -bashio::addon.ingress_entry() { printf '%s' "${ADDON_INGRESS_ENTRY:-}"; } -bashio::addon.ip_address() { printf '%s' "${ADDON_IP_ADDRESS:-}"; } +# ----------------------------------------------------------------------------- +# Addon metadata +# ----------------------------------------------------------------------------- + +bashio::addon.name() { printf '%s' "${ADDON_NAME:-Standalone container}"; } +bashio::addon.description() { printf '%s' "${ADDON_DESCRIPTION:-Standalone mode}"; } +bashio::addon.version() { printf '%s' "${BUILD_VERSION:-1.0}"; } +bashio::addon.version_latest() { printf '%s' "${ADDON_VERSION_LATEST:-${BUILD_VERSION:-1.0}}"; } +bashio::addon.update_available() { [ "${ADDON_VERSION_LATEST:-}" != "${BUILD_VERSION:-}" ] && echo true || echo false; } +bashio::addon.ingress_port() { printf '%s' "${ADDON_INGRESS_PORT:-}"; } +bashio::addon.ingress_entry() { printf '%s' "${ADDON_INGRESS_ENTRY:-}"; } +bashio::addon.ip_address() { printf '%s' "${ADDON_IP_ADDRESS:-}"; } -# Ports: -# - numeric arg "8080" -> env PORT_8080 or ADDON_PORT_8080, falling back to the number -# - non-numeric "WEB_PORT" -> resolve as config/env key bashio::addon.port() { - local arg="${1:-}" + local arg="$1" if [[ "$arg" =~ ^[0-9]+$ ]]; then - local v - v="$(_bashio_env_get "PORT_${arg}")" - [ -z "$v" ] && v="$(_bashio_env_get "ADDON_PORT_${arg}")" - printf '%s' "${v:-$arg}" + printf '%s' "$(_bashio_env_get "PORT_${arg}" || _bashio_env_get "ADDON_PORT_${arg}" || echo "$arg")" else printf '%s' "$(_bashio_env_get "$arg")" fi } -# -------- system info -------------------------------------------------------- +# ----------------------------------------------------------------------------- +# System info +# ----------------------------------------------------------------------------- -bashio::info.operating_system() { - if [ -r /etc/os-release ]; then - . /etc/os-release - printf '%s' "${PRETTY_NAME:-${NAME:-Linux}}" - else - printf '%s' "Linux" - fi -} -bashio::info.arch() { uname -m; } -bashio::info.machine() { uname -m; } -bashio::info.homeassistant() { printf '%s' "standalone"; } -bashio::info.supervisor() { printf '%s' "standalone"; } +bashio::info.operating_system() { . /etc/os-release 2>/dev/null; printf '%s' "${PRETTY_NAME:-Linux}"; } +bashio::info.arch() { uname -m; } +bashio::info.machine() { uname -m; } +bashio::info.homeassistant() { echo "standalone"; } +bashio::info.supervisor() { echo "standalone"; } -# -------- config ------------------------------------------------------------- +# ----------------------------------------------------------------------------- +# Config API +# ----------------------------------------------------------------------------- -# Primary getter: -# 1) ENV (several name variants/prefixes) -# 2) JSON file via STANDALONE_OPTIONS_JSON (jq required) bashio::config() { - local key="${1:-}" - local v - v="$(_bashio_env_get "$key")" - if [ -z "$v" ]; then - v="$(_bashio_json_get "$key")" - fi + local key="$1" + local v="$(_bashio_env_get "$key")" + [ -z "$v" ] && v="$(_bashio_json_get "$key")" printf '%s' "${v:-}" } -bashio::config.has_value() { - local k="$1" - [ -n "$(bashio::config "$k")" ] -} -bashio::config.true() { - local k="$1" - _bashio_is_true "$(bashio::config "$k")" -} +bashio::config.has_value() { [ -n "$(bashio::config "$1")" ]; } +bashio::config.true() { _bashio_is_true "$(bashio::config "$1")"; } +bashio::config.require.ssl() { echo "${REQUIRE_SSL:-true}"; } -# Some add-ons call "require.ssl" (noop by default) -bashio::config.require.ssl() { printf '%s' "${REQUIRE_SSL:-true}"; } - -# -------- variables & fs helpers -------------------------------------------- - -bashio::var.true() { _bashio_is_true "${1:-}"; } -bashio::var.has_value() { [ -n "${1:-}" ]; } +# ----------------------------------------------------------------------------- +# Filesystem helpers +# ----------------------------------------------------------------------------- +bashio::fs.file_exists() { [ -f "$1" ]; } bashio::fs.directory_exists() { [ -d "$1" ]; } +bashio::fs.file_contains() { grep -q -- "$2" "$1" 2>/dev/null; } -# -------- network/services --------------------------------------------------- +# ----------------------------------------------------------------------------- +# Network helpers +# ----------------------------------------------------------------------------- -# Wait for TCP service: bashio::net.wait_for host port [timeout] bashio::net.wait_for() { local host="$1" port="$2" to="${3:-30}" - _bashio_tcp_wait "$host" "$port" "$to" -} - -# Discovery stubs; map to common env names, or JSON: -# Usage patterns seen: -# bashio::services "mqtt" "host" -# bashio::services "mysql" "port" -bashio::services() { - local svc="${1:-}" key="${2:-}" - [ -z "$svc" ] && return 0 - local upper svc_upper var v - upper="$(printf '%s' "$key" | tr '[:lower:]' '[:upper:]')" - svc_upper="$(printf '%s' "$svc" | tr '[:lower:]' '[:upper:]')" - - # Common mappings - case "$svc_upper:$upper" in - MQTT:HOST) var="MQTT_HOST" ;; - MQTT:PORT) var="MQTT_PORT" ;; - MQTT:USERNAME) var="MQTT_USER" ;; - MQTT:PASSWORD) var="MQTT_PASSWORD" ;; - MQTT:TLS) var="MQTT_TLS" ;; - MYSQL:HOST | MARIADB:HOST) var="DB_HOST" ;; - MYSQL:PORT | MARIADB:PORT) var="DB_PORT" ;; - MYSQL:USERNAME | MARIADB:USERNAME) var="DB_USER" ;; - MYSQL:PASSWORD | MARIADB:PASSWORD) var="DB_PASSWORD" ;; - MYSQL:DATABASE | MARIADB:DATABASE) var="DB_NAME" ;; - *) var="${svc_upper}_${upper}" ;; - esac - - v="$(_bashio_env_get "$var")" - if [ -z "$v" ] && [ -n "${STANDALONE_OPTIONS_JSON:-}" ]; then - v="$(_bashio_json_get "services.${svc}.${key}")" - [ -z "$v" ] && v="$(_bashio_json_get "${svc}.${key}")" - fi - printf '%s' "${v:-}" -} - -# ----- extras for broader compatibility -------------------------------------- - -# Simple cache (used by add-ons & bashio itself) -_BASHIO_CACHE_DIR="${BASHIO_CACHE_DIR:-/tmp/.bashio}" -mkdir -p "$_BASHIO_CACHE_DIR" - -bashio::cache.exists() { [ -f "$_BASHIO_CACHE_DIR/${1}.cache" ]; } -bashio::cache.get() { [ -f "$_BASHIO_CACHE_DIR/${1}.cache" ] && cat "$_BASHIO_CACHE_DIR/${1}.cache"; } -bashio::cache.set() { - mkdir -p "$_BASHIO_CACHE_DIR" - printf '%s' "${2:-}" > "$_BASHIO_CACHE_DIR/${1}.cache" -} - -# Filesystem helpers frequently used -bashio::fs.file_exists() { [ -f "$1" ]; } -bashio::fs.directory_exists() { [ -d "$1" ]; } # already defined earlier; keep if present -bashio::fs.file_contains() { - local f="$1" p="$2" - [ -f "$f" ] && grep -q -- "$p" "$f" -} - -# jq wrapper (some add-ons call bashio::jq) -bashio::jq() { command -v jq > /dev/null 2>&1 && jq "$@"; } - -# env presence (even if empty) used by config.exists -_bashio_env_has() { - local key="$1" p v name - [ -z "$key" ] && return 1 - local variants=( - "$key" - "$(printf '%s' "$key" | tr '.' '_')" - "$(printf '%s' "$key" | tr '.' '_' | tr '[:lower:]' '[:upper:]')" - "$(printf '%s' "$key" | tr '[:lower:]' '[:upper:]')" - ) - for v in "${variants[@]}"; do - for p in "" "CFG_" "CONFIG_" "ADDON_" "OPTION_" "OPT_"; do - name="${p}${v}" - if [ -n "${!name+x}" ]; then # defined, even if empty - printf '%s' "$name" - return 0 - fi - done + command -v nc >/dev/null 2>&1 && nc -z -w "$to" "$host" "$port" && return 0 + local start=$(date +%s) + while ! exec 3<>"/dev/tcp/$host/$port" 2>/dev/null; do + (( $(date +%s) - start >= to )) && return 1 + sleep 1 done - return 1 + exec 3>&- 3<&- } -# config.exists : key is present (env or JSON), even if value is empty -bashio::config.exists() { - local key="$1" file="${STANDALONE_OPTIONS_JSON:-}" - _bashio_env_has "$key" && return 0 - if [ -n "$file" ] && command -v jq > /dev/null 2>&1; then - jq -e --arg k "$key" 'haspath(($k|split(".")))' "$file" > /dev/null 2>&1 - return $? - fi - return 1 +# ----------------------------------------------------------------------------- +# Services discovery shim +# ----------------------------------------------------------------------------- + +bashio::services() { + local svc="$1" key="$2" + local env="${svc^^}_${key^^}" + _bashio_env_get "$env" || _bashio_json_get "services.$svc.$key" } -# addon.option : write/delete option in JSON when possible; fallback no-op/env -bashio::addon.option() { - local key="$1" value="${2-__BASHIO_UNSET__}" file="${STANDALONE_OPTIONS_JSON:-}" - if [ -n "$file" ] && command -v jq > /dev/null 2>&1; then - local tmp - tmp="$(mktemp)" - if [ "$value" = "__BASHIO_UNSET__" ]; then - jq --arg k "$key" 'delpath(($k|split(".")))' "$file" > "$tmp" && mv "$tmp" "$file" - else - jq --arg k "$key" --arg v "$value" 'setpath(($k|split(".")); $v)' "$file" > "$tmp" && mv "$tmp" "$file" - fi - return 0 - fi - # Fallbacks: export as env or treat delete as no-op - if [ "$value" != "__BASHIO_UNSET__" ]; then - export "$(printf '%s' "$key" | tr '.' '_' | tr '-' '_')"="$value" - fi -} +bashio::services.available() { [ -n "$(bashio::services "$1" host)" ]; } -# services.available : check if we can resolve at least a host for the service -bashio::services.available() { - local svc="$1" host - host="$(bashio::services "$svc" "host")" - [ -n "$host" ] -} +# ----------------------------------------------------------------------------- +# Cache +# ----------------------------------------------------------------------------- -# var helpers -bashio::var.false() { ! _bashio_is_true "${1:-}"; } -bashio::var.has_value() { [ -n "${1:-}" ]; } # already present; keep if defined +mkdir -p "$BASHIO_CACHE_DIR" +bashio::cache.exists() { [ -f "$BASHIO_CACHE_DIR/$1.cache" ]; } +bashio::cache.get() { cat "$BASHIO_CACHE_DIR/$1.cache" 2>/dev/null; } +bashio::cache.set() { echo "$2" > "$BASHIO_CACHE_DIR/$1.cache"; } -# exits used by many add-ons -bashio::exit.ok() { exit 0; } -bashio::exit.nok() { - local m="${1:-}" - [ -n "$m" ] && bashio::log.red "$m" - exit 1 -} +# ----------------------------------------------------------------------------- +# Arrays +# ----------------------------------------------------------------------------- -# core.check : Supervisor does a config check; allow an overridable command -# Set STANDALONE_CORE_CHECK_CMD="hass --script check_config -c /config" to enable -bashio::core.check() { - if [ -n "${STANDALONE_CORE_CHECK_CMD:-}" ]; then - eval "$STANDALONE_CORE_CHECK_CMD" - else - return 0 - fi -} - -# --- improvements & extra shims --------------------------------------------- - -# Respect NO_COLOR and dumb terminals -if [ -n "${NO_COLOR:-}" ] || [ "${TERM:-}" = "dumb" ]; then - _BASHIO_COLOR=0 -fi - -# net.wait_for: prefer nc if available, fallback to /dev/tcp -_bashio_tcp_wait_nc() { - # $1=host $2=port $3=timeout(s) - command -v nc > /dev/null 2>&1 || return 1 - local host="$1" port="$2" to="${3:-30}" - # BusyBox and OpenBSD nc differ; cover both styles - nc -z -w "$to" "$host" "$port" 2> /dev/null || nc -z "$host" "$port" 2> /dev/null -} -bashio::net.wait_for() { - local host="$1" port="$2" to="${3:-30}" - _bashio_tcp_wait_nc "$host" "$port" "$to" && return 0 - _bashio_tcp_wait "$host" "$port" "$to" -} - -# DNS helper: bashio::dns.host -> prints an IP (or empty) -bashio::dns.host() { - local h="${1:-}" - [ -z "$h" ] && return 1 - if command -v getent > /dev/null 2>&1; then - getent ahostsv4 "$h" | awk '{print $1; exit}' - else - # fallback: try busybox nslookup - nslookup "$h" 2> /dev/null | awk '/^Address: /{print $2; exit}' - fi -} - -# Hostname -bashio::host.hostname() { - command -v hostname > /dev/null 2>&1 && hostname || printf '%s' "${HOSTNAME:-unknown}" -} - -# Home Assistant token (no Supervisor; read from env or JSON) -bashio::homeassistant.token() { - local t="${HOMEASSISTANT_TOKEN:-${HASS_TOKEN:-}}" - if [ -z "$t" ] && [ -n "${STANDALONE_OPTIONS_JSON:-}" ] && command -v jq > /dev/null 2>&1; then - t="$(jq -er '.homeassistant.token // empty' "$STANDALONE_OPTIONS_JSON" 2> /dev/null || true)" - fi - printf '%s' "${t:-}" -} - -# config.array: -# Accepts CSV ("a,b,c"), space/newline-separated text, or JSON array ["a","b"]. -# Prints one item per line (common pattern in add-ons: `mapfile -t arr < <(bashio::config.array key)`). bashio::config.array() { - local key="${1:-}" raw val - raw="$(bashio::config "$key")" + local raw + raw="$(bashio::config "$1")" [ -z "$raw" ] && return 0 - # JSON array? - if command -v jq > /dev/null 2>&1 && printf '%s' "$raw" | jq -e . > /dev/null 2>&1; then - printf '%s' "$raw" | jq -r '.[]' 2> /dev/null && return 0 + if command -v jq >/dev/null 2>&1 && echo "$raw" | jq -e . >/dev/null 2>&1; then + echo "$raw" | jq -r '.[]' + elif [[ "$raw" == *","* ]]; then + tr ',' '\n' <<<"$raw" + else + printf '%s\n' $raw fi - - # CSV -> newline - if printf '%s' "$raw" | grep -q ','; then - printf '%s' "$raw" | tr ',' '\n' - return 0 - fi - - # Already space/newline-separated - printf '%s\n' "$raw" } -# Optional: common require.* shims (treat as advisory in standalone) -bashio::config.require.username() { :; } -bashio::config.require.password() { :; } -bashio::config.require.port() { :; } +# ----------------------------------------------------------------------------- +# Home Assistant token +# ----------------------------------------------------------------------------- -# -------- end ---------------------------------------------------------------- +bashio::homeassistant.token() { + echo "${HOMEASSISTANT_TOKEN:-${HASS_TOKEN:-$(_bashio_json_get 'homeassistant.token')}}" +} + +# ----------------------------------------------------------------------------- +# Exit helpers +# ----------------------------------------------------------------------------- + +bashio::exit.ok() { exit 0; } +bashio::exit.nok() { bashio::log.red "$1"; exit 1; } + +# ----------------------------------------------------------------------------- +# Core config check shim +# ----------------------------------------------------------------------------- + +bashio::core.check() { + [ -n "${STANDALONE_CORE_CHECK_CMD:-}" ] && eval "$STANDALONE_CORE_CHECK_CMD" || true +} diff --git a/.templates/ha_automatic_packages.sh b/.templates/ha_automatic_packages.sh index a58794da6..1aea0f50c 100755 --- a/.templates/ha_automatic_packages.sh +++ b/.templates/ha_automatic_packages.sh @@ -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 diff --git a/addons_updater/Dockerfile b/addons_updater/Dockerfile index 078d68eab..ad93238e7 100644 --- a/addons_updater/Dockerfile +++ b/addons_updater/Dockerfile @@ -65,6 +65,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio # Entrypoint logic diff --git a/arpspoof/Dockerfile b/arpspoof/Dockerfile index bc7e64cd4..2cfaf500b 100644 --- a/arpspoof/Dockerfile +++ b/arpspoof/Dockerfile @@ -64,6 +64,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio ENTRYPOINT [ "/usr/bin/env" ] diff --git a/autobrr/Dockerfile b/autobrr/Dockerfile index 4766712cd..d2b423929 100644 --- a/autobrr/Dockerfile +++ b/autobrr/Dockerfile @@ -72,6 +72,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio #WORKDIR / ENTRYPOINT [ "/usr/bin/env" ] diff --git a/baikal/Dockerfile b/baikal/Dockerfile index 8899abe48..76a1204e3 100644 --- a/baikal/Dockerfile +++ b/baikal/Dockerfile @@ -69,6 +69,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio WORKDIR "/data" diff --git a/battybirdnet-pi/Dockerfile b/battybirdnet-pi/Dockerfile index 8271c7800..f08e66b76 100644 --- a/battybirdnet-pi/Dockerfile +++ b/battybirdnet-pi/Dockerfile @@ -163,6 +163,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio # Avoid config.yaml interference WORKDIR /config diff --git a/bazarr/Dockerfile b/bazarr/Dockerfile index d037cac40..b01c6721a 100644 --- a/bazarr/Dockerfile +++ b/bazarr/Dockerfile @@ -69,6 +69,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio ############ # 5 Labels # diff --git a/binance-trading-bot/Dockerfile b/binance-trading-bot/Dockerfile index b5f4886fa..b8e70210c 100644 --- a/binance-trading-bot/Dockerfile +++ b/binance-trading-bot/Dockerfile @@ -84,6 +84,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio VOLUME [ "/data" ] WORKDIR / diff --git a/birdnet-go/Dockerfile b/birdnet-go/Dockerfile index 175706d2d..b1b48515c 100644 --- a/birdnet-go/Dockerfile +++ b/birdnet-go/Dockerfile @@ -64,6 +64,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio # Avoid config.yaml interference RUN sed -i "s|config.yaml|config_env.yaml|g" /etc/cont-init.d/01-config_yaml.sh diff --git a/birdnet-pi/Dockerfile b/birdnet-pi/Dockerfile index 240405545..0be5f9dd8 100644 --- a/birdnet-pi/Dockerfile +++ b/birdnet-pi/Dockerfile @@ -172,6 +172,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio # Avoid config.yaml interference WORKDIR /config diff --git a/birdnet-pipy/Dockerfile b/birdnet-pipy/Dockerfile index 2e4c60451..f5019b2eb 100644 --- a/birdnet-pipy/Dockerfile +++ b/birdnet-pipy/Dockerfile @@ -95,8 +95,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio ENTRYPOINT [ "/usr/bin/env" ] CMD [ "/ha_entrypoint.sh" ] diff --git a/bitwarden/Dockerfile b/bitwarden/Dockerfile index 879479da7..3730da96b 100644 --- a/bitwarden/Dockerfile +++ b/bitwarden/Dockerfile @@ -95,6 +95,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio # #WORKDIR / diff --git a/booksonic_air/Dockerfile b/booksonic_air/Dockerfile index 735ab47c4..c8e9b8f36 100644 --- a/booksonic_air/Dockerfile +++ b/booksonic_air/Dockerfile @@ -75,6 +75,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio # #WORKDIR / diff --git a/browser_brave/Dockerfile b/browser_brave/Dockerfile index 7f89cb41b..089c10e57 100644 --- a/browser_brave/Dockerfile +++ b/browser_brave/Dockerfile @@ -90,9 +90,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh -# Standalone bashio command -# ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -# RUN chmod 777 /.bashio-standalone.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio #WORKDIR / #ENTRYPOINT [ "/usr/bin/env" ] diff --git a/browser_chromium/Dockerfile b/browser_chromium/Dockerfile index 7f89cb41b..089c10e57 100644 --- a/browser_chromium/Dockerfile +++ b/browser_chromium/Dockerfile @@ -90,9 +90,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh -# Standalone bashio command -# ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -# RUN chmod 777 /.bashio-standalone.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio #WORKDIR / #ENTRYPOINT [ "/usr/bin/env" ] diff --git a/browserless_chrome/Dockerfile b/browserless_chrome/Dockerfile index 1da13717d..5c5acb6b4 100644 --- a/browserless_chrome/Dockerfile +++ b/browserless_chrome/Dockerfile @@ -66,6 +66,13 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + RUN \ sed -i "2a /./ha_entrypoint.sh" ./scripts/start.sh ############ diff --git a/calibre/Dockerfile b/calibre/Dockerfile index b0d316096..af758bce7 100644 --- a/calibre/Dockerfile +++ b/calibre/Dockerfile @@ -78,6 +78,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio # #WORKDIR / diff --git a/calibre_web/Dockerfile b/calibre_web/Dockerfile index 2decd5454..b06ef58a7 100644 --- a/calibre_web/Dockerfile +++ b/calibre_web/Dockerfile @@ -84,6 +84,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio # #WORKDIR / diff --git a/changedetection.io/Dockerfile b/changedetection.io/Dockerfile index 36d62ea58..ef003d055 100644 --- a/changedetection.io/Dockerfile +++ b/changedetection.io/Dockerfile @@ -70,6 +70,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio #WORKDIR / #ENTRYPOINT [ "/usr/bin/env" ] diff --git a/cloudcommander/Dockerfile b/cloudcommander/Dockerfile index fc7a99277..cdf7b92cc 100644 --- a/cloudcommander/Dockerfile +++ b/cloudcommander/Dockerfile @@ -66,6 +66,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio ENTRYPOINT [ "/ha_entrypoint.sh" ] diff --git a/codex/Dockerfile b/codex/Dockerfile index 34ece6729..e82d98433 100644 --- a/codex/Dockerfile +++ b/codex/Dockerfile @@ -63,6 +63,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio VOLUME [ "/data" ] WORKDIR / diff --git a/collabora/Dockerfile b/collabora/Dockerfile index 512671733..195b5b52c 100644 --- a/collabora/Dockerfile +++ b/collabora/Dockerfile @@ -70,6 +70,13 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + WORKDIR / ENTRYPOINT [ "/ha_entrypoint.sh" ] CMD [ "/usr/bin/env" ] diff --git a/comixed/Dockerfile b/comixed/Dockerfile index 5c0a62a65..99eb1ac4a 100644 --- a/comixed/Dockerfile +++ b/comixed/Dockerfile @@ -79,6 +79,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio VOLUME [ "/data" ] WORKDIR / diff --git a/elasticsearch/Dockerfile b/elasticsearch/Dockerfile index 5c37fc4f2..08ba21ebe 100644 --- a/elasticsearch/Dockerfile +++ b/elasticsearch/Dockerfile @@ -77,6 +77,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio ############ # 5 Labels # diff --git a/emby/Dockerfile b/emby/Dockerfile index 5a380e927..88af2041c 100644 --- a/emby/Dockerfile +++ b/emby/Dockerfile @@ -68,6 +68,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio ############ # 5 Labels # diff --git a/emby_beta/Dockerfile b/emby_beta/Dockerfile index b51eb9ab2..fb3da8964 100644 --- a/emby_beta/Dockerfile +++ b/emby_beta/Dockerfile @@ -68,6 +68,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio ############ # 5 Labels # diff --git a/enedisgateway2mqtt/Dockerfile b/enedisgateway2mqtt/Dockerfile index 29eb8d9b9..254653187 100644 --- a/enedisgateway2mqtt/Dockerfile +++ b/enedisgateway2mqtt/Dockerfile @@ -63,6 +63,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio ENTRYPOINT [ "/usr/bin/env" ] diff --git a/enedisgateway2mqtt_dev/Dockerfile b/enedisgateway2mqtt_dev/Dockerfile index 3192f07d0..18e2b9031 100644 --- a/enedisgateway2mqtt_dev/Dockerfile +++ b/enedisgateway2mqtt_dev/Dockerfile @@ -63,6 +63,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio ENTRYPOINT [ "/usr/bin/env" ] diff --git a/epicgamesfree/Dockerfile b/epicgamesfree/Dockerfile index 83e534f18..d12d19327 100644 --- a/epicgamesfree/Dockerfile +++ b/epicgamesfree/Dockerfile @@ -66,6 +66,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio # #WORKDIR / diff --git a/filebrowser/Dockerfile b/filebrowser/Dockerfile index 516b425a0..d8330177c 100644 --- a/filebrowser/Dockerfile +++ b/filebrowser/Dockerfile @@ -66,6 +66,13 @@ RUN chmod 744 /ha_autoapps.sh && /ha_autoapps.sh "$PACKAGES" && rm /ha_autoapps. ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + VOLUME [ "/data" ] WORKDIR / diff --git a/filebrowser_quantum/Dockerfile b/filebrowser_quantum/Dockerfile index ffa17d523..863580748 100644 --- a/filebrowser_quantum/Dockerfile +++ b/filebrowser_quantum/Dockerfile @@ -67,6 +67,13 @@ RUN chmod 744 /ha_autoapps.sh && /ha_autoapps.sh "$PACKAGES" && rm /ha_autoapps. ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + RUN \ sed -i "s|/command/with-contenv|/usr/bin/env|g" "/ha_entrypoint.sh" VOLUME [ "/data" ] diff --git a/fireflyiii/Dockerfile b/fireflyiii/Dockerfile index 86dc56bc7..ec5389c4a 100644 --- a/fireflyiii/Dockerfile +++ b/fireflyiii/Dockerfile @@ -75,6 +75,12 @@ RUN chmod 744 /ha_autoapps.sh && /ha_autoapps.sh "$PACKAGES" && rm /ha_autoapps. ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio #ENTRYPOINT [ "/usr/bin/env" ] #CMD [ "/ha_entrypoint.sh" ] diff --git a/fireflyiii_data_importer/Dockerfile b/fireflyiii_data_importer/Dockerfile index c13f3e7ea..a5b88d091 100644 --- a/fireflyiii_data_importer/Dockerfile +++ b/fireflyiii_data_importer/Dockerfile @@ -77,6 +77,12 @@ RUN chmod 744 /ha_autoapps.sh && /ha_autoapps.sh "$PACKAGES" && rm /ha_autoapps. ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio # Adapt shebang SHELL ["/bin/bash", "-o", "pipefail", "-c"] diff --git a/fireflyiii_fints_importer/Dockerfile b/fireflyiii_fints_importer/Dockerfile index 395db9233..d81a40036 100644 --- a/fireflyiii_fints_importer/Dockerfile +++ b/fireflyiii_fints_importer/Dockerfile @@ -69,7 +69,10 @@ RUN chmod 777 "/ha_entrypoint.sh" # Entrypoint modifications ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint_modif.sh" "/ha_entrypoint_modif.sh" RUN chmod 777 "/ha_entrypoint_modif.sh" -RUN chmod 777 /ha_entrypoint.sh /ha_entrypoint_modif.sh && /ha_entrypoint_modif.sh && rm /ha_entrypoint_modif.sh +RUN chmod 777 /ha_entrypoint.sh + +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" +RUN chmod 0644 /.bashio-standalone.sh /ha_entrypoint_modif.sh && /ha_entrypoint_modif.sh && rm /ha_entrypoint_modif.sh ENTRYPOINT [ "/usr/bin/env" ] diff --git a/flaresolverr/Dockerfile b/flaresolverr/Dockerfile index 61b78fcac..509a33aae 100644 --- a/flaresolverr/Dockerfile +++ b/flaresolverr/Dockerfile @@ -65,6 +65,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio ENTRYPOINT [ "/usr/bin/env" ] diff --git a/flexget/Dockerfile b/flexget/Dockerfile index 10042351c..b1dd85392 100644 --- a/flexget/Dockerfile +++ b/flexget/Dockerfile @@ -81,6 +81,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio # #WORKDIR / diff --git a/free_games_claimer/Dockerfile b/free_games_claimer/Dockerfile index 0352a25b4..c1f1ed2e4 100644 --- a/free_games_claimer/Dockerfile +++ b/free_games_claimer/Dockerfile @@ -63,6 +63,13 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + RUN \ # Change data folder sed -i "s|/fgc|/data|g" /usr/local/bin/docker-entrypoint.sh && \ diff --git a/gazpar2mqtt/Dockerfile b/gazpar2mqtt/Dockerfile index 3cc529347..632be980c 100644 --- a/gazpar2mqtt/Dockerfile +++ b/gazpar2mqtt/Dockerfile @@ -66,6 +66,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio ENTRYPOINT [ "/usr/bin/env" ] diff --git a/gitea/Dockerfile b/gitea/Dockerfile index f6a0d55ec..b8064b12f 100644 --- a/gitea/Dockerfile +++ b/gitea/Dockerfile @@ -68,6 +68,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio ENTRYPOINT [ "/ha_entrypoint.sh" ] diff --git a/grampsweb/Dockerfile b/grampsweb/Dockerfile index 9d0cdb25f..110008e1b 100644 --- a/grampsweb/Dockerfile +++ b/grampsweb/Dockerfile @@ -64,6 +64,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio ENTRYPOINT [ "/usr/bin/env" ] CMD [ "/ha_entrypoint.sh" ] diff --git a/grav/Dockerfile b/grav/Dockerfile index b162ba004..924119863 100644 --- a/grav/Dockerfile +++ b/grav/Dockerfile @@ -72,6 +72,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio ############ # 5 Labels # diff --git a/guacamole/Dockerfile b/guacamole/Dockerfile index dc2c25ea8..ac92c9632 100644 --- a/guacamole/Dockerfile +++ b/guacamole/Dockerfile @@ -90,6 +90,13 @@ RUN chmod 744 /ha_autoapps.sh && /ha_autoapps.sh "$PACKAGES" && rm /ha_autoapps. ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + #WORKDIR /data ENTRYPOINT [ "/usr/bin/env" ] CMD [ "/ha_entrypoint.sh" ] diff --git a/immich/Dockerfile b/immich/Dockerfile index 547ca2814..a46c38b34 100644 --- a/immich/Dockerfile +++ b/immich/Dockerfile @@ -78,6 +78,13 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + RUN \ sed -i "s|postgresql-16|postgresql-15|g" /etc/s6-overlay/s6-rc.d/init-test-run/run # Install dependencies diff --git a/immich_cuda/Dockerfile b/immich_cuda/Dockerfile index 547ca2814..a46c38b34 100644 --- a/immich_cuda/Dockerfile +++ b/immich_cuda/Dockerfile @@ -78,6 +78,13 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + RUN \ sed -i "s|postgresql-16|postgresql-15|g" /etc/s6-overlay/s6-rc.d/init-test-run/run # Install dependencies diff --git a/immich_frame/Dockerfile b/immich_frame/Dockerfile index 2f0214699..56388627e 100644 --- a/immich_frame/Dockerfile +++ b/immich_frame/Dockerfile @@ -65,6 +65,12 @@ RUN chmod 744 /ha_autoapps.sh && /ha_autoapps.sh "$PACKAGES" && rm /ha_autoapps. ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio ENTRYPOINT [ "/usr/bin/env" ] CMD [ "/ha_entrypoint.sh" ] diff --git a/immich_noml/Dockerfile b/immich_noml/Dockerfile index 547ca2814..a46c38b34 100644 --- a/immich_noml/Dockerfile +++ b/immich_noml/Dockerfile @@ -78,6 +78,13 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + RUN \ sed -i "s|postgresql-16|postgresql-15|g" /etc/s6-overlay/s6-rc.d/init-test-run/run # Install dependencies diff --git a/immich_openvino/Dockerfile b/immich_openvino/Dockerfile index 547ca2814..a46c38b34 100644 --- a/immich_openvino/Dockerfile +++ b/immich_openvino/Dockerfile @@ -78,6 +78,13 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + RUN \ sed -i "s|postgresql-16|postgresql-15|g" /etc/s6-overlay/s6-rc.d/init-test-run/run # Install dependencies diff --git a/immich_power_tools/Dockerfile b/immich_power_tools/Dockerfile index 2f0214699..56388627e 100644 --- a/immich_power_tools/Dockerfile +++ b/immich_power_tools/Dockerfile @@ -65,6 +65,12 @@ RUN chmod 744 /ha_autoapps.sh && /ha_autoapps.sh "$PACKAGES" && rm /ha_autoapps. ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio ENTRYPOINT [ "/usr/bin/env" ] CMD [ "/ha_entrypoint.sh" ] diff --git a/inadyn/Dockerfile b/inadyn/Dockerfile index 52b4ee45f..150c2e41d 100644 --- a/inadyn/Dockerfile +++ b/inadyn/Dockerfile @@ -89,6 +89,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio WORKDIR / diff --git a/jackett/Dockerfile b/jackett/Dockerfile index 4b55651d5..23300542d 100644 --- a/jackett/Dockerfile +++ b/jackett/Dockerfile @@ -71,6 +71,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio ############ # 5 Labels # diff --git a/jellyfin/Dockerfile b/jellyfin/Dockerfile index 84de052be..8dd26920d 100644 --- a/jellyfin/Dockerfile +++ b/jellyfin/Dockerfile @@ -79,6 +79,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio # #WORKDIR / diff --git a/jellyseerr/Dockerfile b/jellyseerr/Dockerfile index 2487113ca..b03481399 100644 --- a/jellyseerr/Dockerfile +++ b/jellyseerr/Dockerfile @@ -75,6 +75,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio #ENTRYPOINT [ "/usr/bin/env" ] diff --git a/joal/Dockerfile b/joal/Dockerfile index be4573246..32632fef5 100644 --- a/joal/Dockerfile +++ b/joal/Dockerfile @@ -76,6 +76,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio ENTRYPOINT [ "/usr/bin/env" ] diff --git a/joplin/Dockerfile b/joplin/Dockerfile index f8a7da47b..3fe768529 100644 --- a/joplin/Dockerfile +++ b/joplin/Dockerfile @@ -71,6 +71,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio ENTRYPOINT [ "/usr/bin/env" ] diff --git a/kometa/Dockerfile b/kometa/Dockerfile index 045ae27c7..18bdddfb9 100644 --- a/kometa/Dockerfile +++ b/kometa/Dockerfile @@ -77,6 +77,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio # #WORKDIR / diff --git a/librespeed/Dockerfile b/librespeed/Dockerfile index e35cea510..4f38322c8 100644 --- a/librespeed/Dockerfile +++ b/librespeed/Dockerfile @@ -68,6 +68,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio # #WORKDIR / diff --git a/lidarr/Dockerfile b/lidarr/Dockerfile index ce7f78725..c294d5899 100644 --- a/lidarr/Dockerfile +++ b/lidarr/Dockerfile @@ -71,6 +71,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio # #WORKDIR / diff --git a/linkwarden/Dockerfile b/linkwarden/Dockerfile index ef56b4d6b..7ce5fa271 100644 --- a/linkwarden/Dockerfile +++ b/linkwarden/Dockerfile @@ -78,11 +78,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # Modify .env location RUN sed -i "s|/\.env|/data_linkwarden/\.env|g" /etc/cont-init.d/*.sh diff --git a/mealie/Dockerfile b/mealie/Dockerfile index 8f591fecf..be363af91 100644 --- a/mealie/Dockerfile +++ b/mealie/Dockerfile @@ -95,11 +95,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh RUN \ # Apply custom instructions to run.sh diff --git a/monica/Dockerfile b/monica/Dockerfile index 0aa2889e1..61ad0e431 100644 --- a/monica/Dockerfile +++ b/monica/Dockerfile @@ -100,11 +100,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh ENTRYPOINT [ "/usr/bin/env" ] CMD [ "/ha_entrypoint.sh" ] diff --git a/mylar3/Dockerfile b/mylar3/Dockerfile index 4b5f50791..b71a8307c 100644 --- a/mylar3/Dockerfile +++ b/mylar3/Dockerfile @@ -68,11 +68,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # #WORKDIR / diff --git a/navidrome/Dockerfile b/navidrome/Dockerfile index e98e36565..1be5ec739 100644 --- a/navidrome/Dockerfile +++ b/navidrome/Dockerfile @@ -67,11 +67,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh ENTRYPOINT [ "/ha_entrypoint.sh" ] diff --git a/netalertx/Dockerfile b/netalertx/Dockerfile index 40216dcfa..533fe40db 100644 --- a/netalertx/Dockerfile +++ b/netalertx/Dockerfile @@ -102,7 +102,10 @@ ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templat # Entrypoint modifications ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint_modif.sh" "/ha_entrypoint_modif.sh" -RUN chmod 777 /ha_entrypoint.sh /ha_entrypoint_modif.sh \ +RUN chmod 777 /ha_entrypoint.sh + +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" +RUN chmod 0644 /.bashio-standalone.sh /ha_entrypoint_modif.sh \ && /ha_entrypoint_modif.sh \ && rm /ha_entrypoint_modif.sh diff --git a/nextcloud/Dockerfile b/nextcloud/Dockerfile index fe24d262f..3181b28d9 100644 --- a/nextcloud/Dockerfile +++ b/nextcloud/Dockerfile @@ -107,11 +107,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # Correct modifications ARG CONFIGLOCATION="/www/nextcloud/config" diff --git a/nzbget/Dockerfile b/nzbget/Dockerfile index 0f915172a..ad5c4952d 100644 --- a/nzbget/Dockerfile +++ b/nzbget/Dockerfile @@ -68,11 +68,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # #WORKDIR / diff --git a/ombi/Dockerfile b/ombi/Dockerfile index 9a5d9d5d0..b70b0c01e 100644 --- a/ombi/Dockerfile +++ b/ombi/Dockerfile @@ -69,11 +69,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # #WORKDIR / diff --git a/omni-tools/Dockerfile b/omni-tools/Dockerfile index d8683bd7a..a1adea34b 100644 --- a/omni-tools/Dockerfile +++ b/omni-tools/Dockerfile @@ -67,11 +67,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh VOLUME [ "/data" ] WORKDIR / diff --git a/openproject/Dockerfile b/openproject/Dockerfile index fde314fd3..bfa3f542b 100644 --- a/openproject/Dockerfile +++ b/openproject/Dockerfile @@ -76,11 +76,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh ENTRYPOINT [ "/usr/bin/env" ] CMD [ "/ha_entrypoint.sh" ] diff --git a/organizr/Dockerfile b/organizr/Dockerfile index d20c01a30..c47058edf 100644 --- a/organizr/Dockerfile +++ b/organizr/Dockerfile @@ -67,11 +67,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh RUN sed -i "s|/usr/bin/env|/usr/bin/with-contenv|g" /etc/cont-init.d/* diff --git a/overseerr/Dockerfile b/overseerr/Dockerfile index 041bde97f..f587c21f8 100644 --- a/overseerr/Dockerfile +++ b/overseerr/Dockerfile @@ -69,11 +69,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # #WORKDIR / diff --git a/photoprism/Dockerfile b/photoprism/Dockerfile index 9f77556bb..4b7102aca 100644 --- a/photoprism/Dockerfile +++ b/photoprism/Dockerfile @@ -74,11 +74,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh ENTRYPOINT [ "/usr/bin/env" ] CMD [ "/ha_entrypoint.sh" ] diff --git a/piwigo/Dockerfile b/piwigo/Dockerfile index 2e4529764..2022cfc21 100644 --- a/piwigo/Dockerfile +++ b/piwigo/Dockerfile @@ -70,11 +70,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # hadolint ignore=SC2013 RUN \ diff --git a/plex/Dockerfile b/plex/Dockerfile index 840f792aa..79894ad50 100644 --- a/plex/Dockerfile +++ b/plex/Dockerfile @@ -82,11 +82,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # #WORKDIR / diff --git a/portainer/Dockerfile b/portainer/Dockerfile index 20676d4ac..6cf8c6f84 100644 --- a/portainer/Dockerfile +++ b/portainer/Dockerfile @@ -86,11 +86,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh RUN chmod 777 /etc/services.d/*/* # diff --git a/portainer_agent/Dockerfile b/portainer_agent/Dockerfile index 7ec9ba0a4..e8b234935 100644 --- a/portainer_agent/Dockerfile +++ b/portainer_agent/Dockerfile @@ -77,6 +77,13 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + RUN chmod a+x /usr/sbin/healthcheck && \ chmod a+x /usr/sbin/wait-for-signal WORKDIR "/app" diff --git a/postgres_15/Dockerfile b/postgres_15/Dockerfile index e29d3ad38..a8f9bd6a4 100644 --- a/postgres_15/Dockerfile +++ b/postgres_15/Dockerfile @@ -70,11 +70,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh RUN sed -i "/Termination signal received/a gosu postgres pg_ctl -D \"\$PGDATA\" -m fast stop" /ha_entrypoint.sh diff --git a/prowlarr/Dockerfile b/prowlarr/Dockerfile index 402437937..bc4b978b2 100644 --- a/prowlarr/Dockerfile +++ b/prowlarr/Dockerfile @@ -71,11 +71,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # #WORKDIR / diff --git a/qbittorrent/Dockerfile b/qbittorrent/Dockerfile index bb51a4b1d..0f8000a5f 100644 --- a/qbittorrent/Dockerfile +++ b/qbittorrent/Dockerfile @@ -133,11 +133,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh ############ # 5 Labels # diff --git a/radarr/Dockerfile b/radarr/Dockerfile index 9225cfa33..4026174c0 100644 --- a/radarr/Dockerfile +++ b/radarr/Dockerfile @@ -72,11 +72,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # #WORKDIR / diff --git a/readarr/Dockerfile b/readarr/Dockerfile index 87f25271d..04c5fbd9a 100644 --- a/readarr/Dockerfile +++ b/readarr/Dockerfile @@ -69,11 +69,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # #WORKDIR / diff --git a/requestrr/Dockerfile b/requestrr/Dockerfile index 6a9edf20e..609957a32 100644 --- a/requestrr/Dockerfile +++ b/requestrr/Dockerfile @@ -71,11 +71,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # WORKDIR / diff --git a/resiliosync/Dockerfile b/resiliosync/Dockerfile index 5dcf1cee8..47aca5b10 100644 --- a/resiliosync/Dockerfile +++ b/resiliosync/Dockerfile @@ -90,11 +90,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # #WORKDIR / diff --git a/sabnzbd/Dockerfile b/sabnzbd/Dockerfile index 0f915172a..ad5c4952d 100644 --- a/sabnzbd/Dockerfile +++ b/sabnzbd/Dockerfile @@ -68,11 +68,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # #WORKDIR / diff --git a/scrutiny/Dockerfile b/scrutiny/Dockerfile index 34c8155d0..abbcdf3a2 100644 --- a/scrutiny/Dockerfile +++ b/scrutiny/Dockerfile @@ -66,11 +66,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh ENTRYPOINT [ "/usr/bin/env" ] CMD [ "/ha_entrypoint.sh" ] diff --git a/scrutiny_fa/Dockerfile b/scrutiny_fa/Dockerfile index 01b114d79..4adeaed79 100644 --- a/scrutiny_fa/Dockerfile +++ b/scrutiny_fa/Dockerfile @@ -63,11 +63,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh RUN sed -i "1a if ! bashio::require.unprotected; then bashio::addon.stop; fi" /etc/cont-init.d/90-run.sh diff --git a/seafile/Dockerfile b/seafile/Dockerfile index 5d4d2c0f4..807534b5c 100644 --- a/seafile/Dockerfile +++ b/seafile/Dockerfile @@ -69,11 +69,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh ENTRYPOINT [ "/usr/bin/env" ] diff --git a/signalk/Dockerfile b/signalk/Dockerfile index cf7403744..9bb366e6f 100644 --- a/signalk/Dockerfile +++ b/signalk/Dockerfile @@ -72,11 +72,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # Restart the addon on crash RUN echo "bashio::addon.restart" >> /ha_entrypoint.sh diff --git a/social_to_mealie/Dockerfile b/social_to_mealie/Dockerfile index 50dd6c387..8199c2636 100644 --- a/social_to_mealie/Dockerfile +++ b/social_to_mealie/Dockerfile @@ -65,11 +65,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh ENTRYPOINT [ "/ha_entrypoint.sh" ] diff --git a/sonarr/Dockerfile b/sonarr/Dockerfile index eb3df3289..b395577c2 100644 --- a/sonarr/Dockerfile +++ b/sonarr/Dockerfile @@ -72,11 +72,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # #WORKDIR / diff --git a/sponsorblockcast/Dockerfile b/sponsorblockcast/Dockerfile index 9cb1cc27c..d2bd1bd80 100644 --- a/sponsorblockcast/Dockerfile +++ b/sponsorblockcast/Dockerfile @@ -65,11 +65,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # Entrypoint logic diff --git a/spotweb/Dockerfile b/spotweb/Dockerfile index 3dcde2a80..3934672b9 100644 --- a/spotweb/Dockerfile +++ b/spotweb/Dockerfile @@ -122,11 +122,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh ############ # 5 Labels # diff --git a/tandoor_recipes/Dockerfile b/tandoor_recipes/Dockerfile index ff2cc0fba..cfa8c363a 100644 --- a/tandoor_recipes/Dockerfile +++ b/tandoor_recipes/Dockerfile @@ -63,11 +63,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh #WORKDIR /data/recipes diff --git a/tdarr/Dockerfile b/tdarr/Dockerfile index 5eb8736f2..a2545041c 100644 --- a/tdarr/Dockerfile +++ b/tdarr/Dockerfile @@ -63,11 +63,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh ############ # 5 Labels # diff --git a/teamspeak/Dockerfile b/teamspeak/Dockerfile index 07dec3381..09a27cb8b 100644 --- a/teamspeak/Dockerfile +++ b/teamspeak/Dockerfile @@ -70,11 +70,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # #WORKDIR / diff --git a/transmission/Dockerfile b/transmission/Dockerfile index 9883a9e7f..804b4dc52 100644 --- a/transmission/Dockerfile +++ b/transmission/Dockerfile @@ -79,11 +79,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # #WORKDIR / diff --git a/transmission_openvpn/Dockerfile b/transmission_openvpn/Dockerfile index 4e97a5c14..a9a1d6348 100644 --- a/transmission_openvpn/Dockerfile +++ b/transmission_openvpn/Dockerfile @@ -69,11 +69,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh CMD [ "/ha_entrypoint.sh" ] diff --git a/ubooquity/Dockerfile b/ubooquity/Dockerfile index 1baa4e19c..fea1a6c90 100644 --- a/ubooquity/Dockerfile +++ b/ubooquity/Dockerfile @@ -82,11 +82,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # #WORKDIR / diff --git a/unpackerr/Dockerfile b/unpackerr/Dockerfile index 2684240f0..c43d350e3 100644 --- a/unpackerr/Dockerfile +++ b/unpackerr/Dockerfile @@ -67,11 +67,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh ############ # 5 Labels # diff --git a/webtop_kde/Dockerfile b/webtop_kde/Dockerfile index df6b3d4bd..031f05b6f 100644 --- a/webtop_kde/Dockerfile +++ b/webtop_kde/Dockerfile @@ -85,11 +85,16 @@ RUN chmod 744 /ha_autoapps.sh && /ha_autoapps.sh "$PACKAGES" && rm /ha_autoapps. ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh #WORKDIR / ENTRYPOINT [ "/usr/bin/env" ] diff --git a/webtrees/Dockerfile b/webtrees/Dockerfile index 7ce2a079b..c88fd4297 100644 --- a/webtrees/Dockerfile +++ b/webtrees/Dockerfile @@ -87,11 +87,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh ENTRYPOINT [ "/usr/bin/env" ] CMD [ "/ha_entrypoint.sh" ] diff --git a/wger/Dockerfile b/wger/Dockerfile index 4f2390d26..43815ab81 100644 --- a/wger/Dockerfile +++ b/wger/Dockerfile @@ -76,11 +76,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh USER wger #ENTRYPOINT ["/usr/bin/env"] diff --git a/whatsapper/Dockerfile b/whatsapper/Dockerfile index 441073a89..893cedab4 100644 --- a/whatsapper/Dockerfile +++ b/whatsapper/Dockerfile @@ -67,11 +67,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh #ENTRYPOINT [ "/ha_entrypoint.sh" ] diff --git a/whoogle/Dockerfile b/whoogle/Dockerfile index 73cf0e27d..4536751cf 100644 --- a/whoogle/Dockerfile +++ b/whoogle/Dockerfile @@ -69,11 +69,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh ENTRYPOINT [ "/usr/bin/env" ] diff --git a/xteve/Dockerfile b/xteve/Dockerfile index eb076cb21..8d0cb0c40 100644 --- a/xteve/Dockerfile +++ b/xteve/Dockerfile @@ -69,11 +69,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # #WORKDIR / diff --git a/zoneminder/Dockerfile b/zoneminder/Dockerfile index 343dce0a7..17c8c4308 100644 --- a/zoneminder/Dockerfile +++ b/zoneminder/Dockerfile @@ -74,11 +74,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh ENTRYPOINT [ "/usr/bin/env" ] diff --git a/zzz_archived_code-server/Dockerfile b/zzz_archived_code-server/Dockerfile index 268a1e649..929379d09 100644 --- a/zzz_archived_code-server/Dockerfile +++ b/zzz_archived_code-server/Dockerfile @@ -69,11 +69,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh # #WORKDIR / diff --git a/zzz_archived_omada/Dockerfile b/zzz_archived_omada/Dockerfile index 3cb1eee18..006ebcd9f 100644 --- a/zzz_archived_omada/Dockerfile +++ b/zzz_archived_omada/Dockerfile @@ -67,11 +67,16 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio + COPY rootfs/ / RUN find . -type f \( -name "*.sh" -o -name "run" \) -print -exec chmod +x {} \; -ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/.bashio-standalone.sh" -RUN chmod 777 /.bashio-standalone.sh #ENTRYPOINT [ "/ha_entrypoint.sh" ] #CMD [ "/ha_entrypoint.sh" ] diff --git a/zzz_archived_omada_v3/Dockerfile b/zzz_archived_omada_v3/Dockerfile index 35a52d106..3fced4640 100644 --- a/zzz_archived_omada_v3/Dockerfile +++ b/zzz_archived_omada_v3/Dockerfile @@ -73,6 +73,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio # #ENTRYPOINT [ "/usr/bin/env" ] diff --git a/zzz_archived_paperless_ngx/Dockerfile b/zzz_archived_paperless_ngx/Dockerfile index 6188bb4de..f40e3d5c1 100644 --- a/zzz_archived_paperless_ngx/Dockerfile +++ b/zzz_archived_paperless_ngx/Dockerfile @@ -67,6 +67,12 @@ RUN chmod 744 /ha_autoapps.sh && /ha_autoapps.sh "$PACKAGES" && rm /ha_autoapps. #ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio # Add custom scripts RUN sed -i "2a source /ha_entrypoint.sh" /sbin/docker-entrypoint.sh && \ diff --git a/zzz_archived_papermerge/Dockerfile b/zzz_archived_papermerge/Dockerfile index 32432bc8f..db0834a43 100644 --- a/zzz_archived_papermerge/Dockerfile +++ b/zzz_archived_papermerge/Dockerfile @@ -79,6 +79,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio # #WORKDIR / diff --git a/zzz_archived_plex_meta_manager/Dockerfile b/zzz_archived_plex_meta_manager/Dockerfile index 7a7191eec..45bb3767a 100644 --- a/zzz_archived_plex_meta_manager/Dockerfile +++ b/zzz_archived_plex_meta_manager/Dockerfile @@ -77,6 +77,12 @@ ENV S6_STAGE2_HOOK=/ha_entrypoint.sh ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_entrypoint.sh" "/ha_entrypoint.sh" RUN chmod 777 /ha_entrypoint.sh +# Install bashio +ENV PATH="/usr/local/bin:${PATH}" +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-standalone.sh" "/usr/local/lib/bashio-standalone.sh" +RUN chmod 0755 /usr/local/lib/bashio-standalone.sh +ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/bashio-router.sh" "/usr/local/bin/bashio" +RUN chmod 0755 /usr/local/bin/bashio # #WORKDIR /