#!/bin/bash# Launcher for beszel-agent, installed alongside the agent binary by# Homebrew formulas (`henrygd/beszel` tap and homebrew-core) so that# `brew services` runs the agent with the user's configuration.## Sources environment variables (KEY, TOKEN, HUB_URL, ...) from the env# file created by install-agent-brew.sh, then executes the beszel-agent# binary located in the same directory as this script.# Export all variables defined in the env file.set -aif [ -f "$HOME/.config/beszel/beszel-agent.env" ]; thensource "$HOME/.config/beszel/beszel-agent.env"fiset +aexec "$(dirname "$0")/beszel-agent" "$@"