VAAPI decode via Intel UHD 630, CPU detection, 2x Reolink RLC-540 placeholders. MQTT to local mosquitto (127.0.0.1), 7-day recording retention. Secrets in /opt/homelab/config/frigate/frigate.env on node. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
27 lines
882 B
Bash
Executable file
27 lines
882 B
Bash
Executable file
#!/usr/bin/env bash
|
|
# deploy-frigate.sh - Deploy Frigate NVR on chelsty-infra (print or SSH)
|
|
|
|
MODE="print"
|
|
[[ "$1" == "--ssh" ]] && MODE="ssh"
|
|
|
|
TARGET="100.122.201.22"
|
|
NODE="chelsty-infra"
|
|
REPO_PATH="/home/oskar/homelab-codex-ws"
|
|
SERVICE_PATH="$REPO_PATH/hosts/chelsty-infra/runtime/frigate"
|
|
|
|
echo "HOST: $NODE"
|
|
echo "MODE: $MODE"
|
|
echo "TARGET: $TARGET"
|
|
|
|
# Secrets must exist at /opt/homelab/config/frigate/frigate.env on the node
|
|
# before first deploy. See config.yml for required variables.
|
|
DEPLOY_CMD="cd $REPO_PATH && git fetch origin && git checkout master && git pull origin master && cd $SERVICE_PATH && docker compose up -d --pull always"
|
|
|
|
if [[ "$MODE" == "ssh" ]]; then
|
|
echo "--- Deploying Frigate to $NODE ($TARGET) via SSH ---"
|
|
ssh oskar@$TARGET "$DEPLOY_CMD"
|
|
else
|
|
echo "# --- Deployment commands for $NODE ---"
|
|
echo "ssh oskar@$TARGET '$DEPLOY_CMD'"
|
|
fi
|