Files
hassio-addons/netbird-server/rootfs/etc/services.d/dashboard/run
2026-02-08 19:31:20 +01:00

26 lines
703 B
Plaintext

#!/usr/bin/with-contenv bashio
# shellcheck shell=bash
set -euo pipefail
# ==============================================================================
# Home Assistant Add-on: NetBird Server
# Runs the NetBird Dashboard
# ==============================================================================
ENV_FILE="/config/netbird/dashboard/env"
if [[ -f "$ENV_FILE" ]]; then
set -a
# shellcheck disable=SC1090
. "$ENV_FILE"
set +a
else
bashio::log.error "Missing dashboard env file at ${ENV_FILE}."
bashio::exit.nok
fi
bashio::log.info "Preparing NetBird Dashboard assets..."
/usr/local/bin/init_react_envs.sh
bashio::log.info "Starting NetBird Dashboard..."
exec nginx -g "daemon off;"