From b3a810ba07a594e4a02d145f776bdcec368e417c Mon Sep 17 00:00:00 2001 From: reachableceo Date: Thu, 30 Jul 2026 12:12:43 -0500 Subject: [PATCH] fix: make all scripts resolve paths relative to repo root CloneVendorRepos.sh and CleanVendor.sh resolved vendor/ relative to scripts/ instead of the repo root, so vendor repos were cloned to the wrong location (scripts/vendor) and docker-compose builds (which expect ./vendor at repo root) would fail. BuildAll.sh and StatusCheck.sh had the same issue, cd-ing to scripts/ instead of the repo root before running docker compose. Also updated validate-all.sh with the 10 newer MCP servers that were added after the script was last maintained (firefly-iii, actual, paperless, beszel, gitea, grafana, ha, limesurvey, linkwarden, superset) plus added missing env vars for audiobook-mcp and drawio-mcp. --- scripts/BuildAll.sh | 4 ++-- scripts/CleanVendor.sh | 5 +++-- scripts/CloneVendorRepos.sh | 5 +++-- scripts/StatusCheck.sh | 4 ++-- scripts/validate-all.sh | 18 ++++++++++++++++-- 5 files changed, 26 insertions(+), 10 deletions(-) diff --git a/scripts/BuildAll.sh b/scripts/BuildAll.sh index 60bb852..0c593ce 100755 --- a/scripts/BuildAll.sh +++ b/scripts/BuildAll.sh @@ -17,8 +17,8 @@ echo "" echo "Building all services..." echo "" -# Change to project directory -cd "$(dirname "${BASH_SOURCE[0]}")" +# Change to project root (parent of scripts/) +cd "$(dirname "${BASH_SOURCE[0]}")/.." # Get list of all services from docker-compose.yml SERVICES=$(docker compose config --services) diff --git a/scripts/CleanVendor.sh b/scripts/CleanVendor.sh index 40a497a..9645011 100755 --- a/scripts/CleanVendor.sh +++ b/scripts/CleanVendor.sh @@ -22,8 +22,9 @@ if [ "$CONFIRM" != "yes" ]; then exit 0 fi -# Vendor directory -VENDOR_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)/vendor" +# Vendor directory (repo root is parent of scripts/) +REPO_ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)" +VENDOR_DIR="$REPO_ROOT/vendor" echo "" echo "Removing vendor directories..." diff --git a/scripts/CloneVendorRepos.sh b/scripts/CloneVendorRepos.sh index 9ae6fad..da5ef54 100755 --- a/scripts/CloneVendorRepos.sh +++ b/scripts/CloneVendorRepos.sh @@ -11,8 +11,9 @@ GREEN='\033[0;32m' YELLOW='\033[1;33m' NC='\033[0m' # No Color -# Vendor directory -VENDOR_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)/vendor" +# Vendor directory (repo root is parent of scripts/) +REPO_ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)" +VENDOR_DIR="$REPO_ROOT/vendor" echo -e "${GREEN}=== KNEL-AIMiddleware Vendor Repository Clone Script ===${NC}" echo "" diff --git a/scripts/StatusCheck.sh b/scripts/StatusCheck.sh index 8f8f1dd..6376afb 100755 --- a/scripts/StatusCheck.sh +++ b/scripts/StatusCheck.sh @@ -15,8 +15,8 @@ NC='\033[0m' # No Color echo -e "${BLUE}=== KNEL-AIMiddleware Service Status Check ===${NC}" echo "" -# Change to project directory -cd "$(dirname "${BASH_SOURCE[0]}")" +# Change to project root (parent of scripts/) +cd "$(dirname "${BASH_SOURCE[0]}")/.." # Get list of all services from docker-compose.yml SERVICES=$(docker compose config --services | sort) diff --git a/scripts/validate-all.sh b/scripts/validate-all.sh index 75a8f44..33a6306 100755 --- a/scripts/validate-all.sh +++ b/scripts/validate-all.sh @@ -72,12 +72,26 @@ MCP_SERVERS=( ["kneldevstack-aimiddleware-bitwarden-mcp"]="15 BITWARDEN_CLIENT_ID=dummy BITWARDEN_CLIENT_SECRET=dummy BITWARDEN_PASSWORD=dummy BITWARDEN_SERVER_URL=https://vault.bitwarden.com" # Productivity & Automation - ["kneldevstack-aimiddleware-audiobook-mcp"]="10" + ["kneldevstack-aimiddleware-audiobook-mcp"]="10 AUDIOBOOK_ROOT=/tmp" ["kneldevstack-aimiddleware-snipeit-mcp"]="10 SNIPEIT_URL=https://snipeit.example.com SNIPEIT_TOKEN=dummy" ["kneldevstack-aimiddleware-mcp-redmine"]="10 REDMINE_URL=https://redmine.example.com REDMINE_API_KEY=dummy" ["kneldevstack-aimiddleware-mcp-ansible"]="10" ["kneldevstack-aimiddleware-elasticsearch-mcp"]="10 ELASTICSEARCH_URL=http://localhost:9200 ELASTICSEARCH_USERNAME=dummy ELASTICSEARCH_PASSWORD=dummy" - ["kneldevstack-aimiddleware-drawio-mcp"]="10" + ["kneldevstack-aimiddleware-drawio-mcp"]="10 DRAWIO_URL=https://drawio.example.com" + + # Financial & Budgeting + ["kneldevstack-aimiddleware-firefly-iii-mcp"]="10 FIREFLY_III_BASE_URL=https://firefly.example.com FIREFLY_III_PAT=dummy" + ["kneldevstack-aimiddleware-actual-mcp"]="10 ACTUAL_SERVER_URL=https://actual.example.com ACTUAL_PASSWORD=dummy ACTUAL_BUDGET_SYNC_ID=dummy" + ["kneldevstack-aimiddleware-paperless-mcp"]="10" + + # Additional Productivity + ["kneldevstack-aimiddleware-beszel-mcp"]="10 BESZEL_URL=https://beszel.example.com BESZEL_USERNAME=dummy BESZEL_PASSWORD=dummy" + ["kneldevstack-aimiddleware-gitea-mcp"]="10 GITEA_URL=https://gitea.example.com GITEA_TOKEN=dummy" + ["kneldevstack-aimiddleware-mcp-grafana"]="10 GRAFANA_URL=https://grafana.example.com GRAFANA_TOKEN=dummy" + ["kneldevstack-aimiddleware-ha-mcp"]="10 HOMEASSISTANT_URL=https://ha.example.com HOMEASSISTANT_TOKEN=dummy" + ["kneldevstack-aimiddleware-limesurvey-mcp"]="10 LIMESURVEY_URL=https://limesurvey.example.com LIMESURVEY_USERNAME=dummy LIMESURVEY_PASSWORD=dummy" + ["kneldevstack-aimiddleware-linkwarden-mcp"]="10 LINKWARDEN_URL=https://linkwarden.example.com LINKWARDEN_TOKEN=dummy" + ["kneldevstack-aimiddleware-superset-mcp"]="10 SUPERSET_URL=https://superset.example.com SUPERSET_USERNAME=dummy SUPERSET_PASSWORD=dummy" # Additional Tools ["kneldevstack-aimiddleware-penpot-mcp"]="10 PENPOT_URL=https://design.penpot.app PENPOT_TOKEN=dummy"