You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
466 B
17 lines
466 B
#!/usr/bin/env bash
|
|
# scripts/reindex.sh — Trigger a full vault reindex via the API.
|
|
|
|
set -euo pipefail
|
|
|
|
API_URL="${API_URL:-http://localhost:8000}"
|
|
FORCE="${1:-false}"
|
|
|
|
echo "🔄 Triggering vault reindex (force=$FORCE)..."
|
|
|
|
RESPONSE=$(curl -sf -X POST "$API_URL/api/v1/index/reindex" \
|
|
-H "Content-Type: application/json" \
|
|
-d "{\"force\": $FORCE}")
|
|
|
|
echo "$RESPONSE" | python3 -m json.tool 2>/dev/null || echo "$RESPONSE"
|
|
echo "✓ Reindex job queued."
|