#!/usr/bin/env bash # HarborForge.PlexumPlugin installer. set -euo pipefail REPO="$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")/.." && pwd)" PROFILE_DIR="${HOME}/.plexum" while [[ $# -gt 0 ]]; do case "$1" in --profile) PROFILE_DIR="$2"; shift 2 ;; -h|--help) sed -n '2,/^set -euo/p' "$0" | sed 's/^# \{0,1\}//'; exit 0 ;; *) echo "unknown flag: $1" >&2; exit 2 ;; esac done log() { printf '\033[1;34m[hf-install]\033[0m %s\n' "$*"; } command -v go >/dev/null || { echo "go not found on PATH" >&2; exit 1; } PLUGIN_DIR="${PROFILE_DIR}/plugins/harbor-forge" mkdir -p "${PLUGIN_DIR}" cd "${REPO}" VERSION="$(git describe --tags --always 2>/dev/null || echo dev)" LDFLAGS="-X main.Version=${VERSION}" log "building plexum-harborforge-plugin (v=${VERSION})" CGO_ENABLED=0 go build -ldflags="${LDFLAGS}" \ -o "${PLUGIN_DIR}/plexum-harborforge-plugin" \ ./cmd/plexum-harborforge-plugin cp manifest.json "${PLUGIN_DIR}/manifest.json" log "installed binary + manifest to ${PLUGIN_DIR}" cat <", "monitor_push_enabled": true, "monitor_push_interval_seconds": 30, "monitor_port": 0, "calendar_enabled": true, "calendar_heartbeat_interval_seconds": 30 } 3. Restart the host: systemctl --user restart plexum 4. Verify push is landing (DB last_seen_at advancing) and then remove the standalone harborforge-monitor container. EOF