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

24 lines
657 B
Plaintext

#!/usr/bin/with-contenv bashio
# shellcheck shell=bash
set -euo pipefail
# ==============================================================================
# Home Assistant Add-on: NetBird Server
# Runs the NetBird Relay (includes embedded STUN)
# ==============================================================================
RELAY_ENV_FILE="/config/netbird/relay/relay.env"
if [[ -f "$RELAY_ENV_FILE" ]]; then
set -a
# shellcheck disable=SC1090
. "$RELAY_ENV_FILE"
set +a
else
bashio::log.error "Missing relay env file at ${RELAY_ENV_FILE}."
bashio::exit.nok
fi
bashio::log.info "Starting NetBird Relay..."
exec /usr/local/bin/netbird-relay