fix(ci): Spawn ingestion container on breakpilot-network
Some checks failed
CI/CD / go-lint (push) Has been skipped
CI/CD / python-lint (push) Has been skipped
CI/CD / nodejs-lint (push) Has been skipped
CI/CD / test-go-ai-compliance (push) Successful in 36s
CI/CD / test-python-backend-compliance (push) Successful in 36s
CI/CD / test-python-document-crawler (push) Successful in 49s
CI/CD / test-python-dsms-gateway (push) Successful in 23s
CI/CD / deploy-hetzner (push) Failing after 1s
Some checks failed
CI/CD / go-lint (push) Has been skipped
CI/CD / python-lint (push) Has been skipped
CI/CD / nodejs-lint (push) Has been skipped
CI/CD / test-go-ai-compliance (push) Successful in 36s
CI/CD / test-python-backend-compliance (push) Successful in 36s
CI/CD / test-python-document-crawler (push) Successful in 49s
CI/CD / test-python-dsms-gateway (push) Successful in 23s
CI/CD / deploy-hetzner (push) Failing after 1s
Instead of trying to connect the runner to breakpilot-network, spawn a new alpine container directly on it via docker run. Added debug output for network/container visibility. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -30,16 +30,6 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
git clone --depth 1 --branch main ${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}.git .
|
git clone --depth 1 --branch main ${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}.git .
|
||||||
|
|
||||||
- name: Join breakpilot-network
|
|
||||||
run: |
|
|
||||||
# Runner-Container ans breakpilot-network anhaengen,
|
|
||||||
# damit bp-core-rag-service erreichbar ist
|
|
||||||
CONTAINER_ID=$(cat /etc/hostname)
|
|
||||||
echo "Runner container: $CONTAINER_ID"
|
|
||||||
docker network connect breakpilot-network "$CONTAINER_ID" 2>/dev/null \
|
|
||||||
&& echo "Verbunden mit breakpilot-network" \
|
|
||||||
|| echo "WARNUNG: breakpilot-network nicht verfuegbar"
|
|
||||||
|
|
||||||
- name: Run Ingestion
|
- name: Run Ingestion
|
||||||
run: |
|
run: |
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
@@ -48,32 +38,35 @@ jobs:
|
|||||||
echo "=== RAG Ingestion: Phase ${PHASE} ==="
|
echo "=== RAG Ingestion: Phase ${PHASE} ==="
|
||||||
echo ""
|
echo ""
|
||||||
|
|
||||||
export WORK_DIR="/tmp/rag-ingestion"
|
# Debug: Netzwerke und laufende Container anzeigen
|
||||||
export QDRANT_URL="https://qdrant-dev.breakpilot.ai"
|
echo "--- Docker Networks ---"
|
||||||
export RAG_URL="http://bp-core-rag-service:8097/api/v1/documents/upload"
|
docker network ls 2>/dev/null || echo "docker network ls fehlgeschlagen"
|
||||||
export SDK_URL="http://bp-compliance-ai-sdk:8090"
|
echo ""
|
||||||
|
echo "--- RAG-relevante Container ---"
|
||||||
mkdir -p "$WORK_DIR"/{pdfs,repos,texts}
|
docker ps --filter name=rag --format "{{.Names}} {{.Status}}" 2>/dev/null || true
|
||||||
|
docker ps --filter name=bp-core --format "{{.Names}} {{.Status}}" 2>/dev/null || true
|
||||||
echo "RAG API: $RAG_URL"
|
|
||||||
echo "Qdrant: $QDRANT_URL"
|
|
||||||
echo "Work Dir: $WORK_DIR"
|
|
||||||
echo ""
|
echo ""
|
||||||
|
|
||||||
# Health Check: RAG ueber Container-Netzwerk erreichbar?
|
# Ingestion in einem Container auf breakpilot-network ausfuehren.
|
||||||
if ! curl -sf "$RAG_URL" -X POST -o /dev/null 2>/dev/null; then
|
# Der Runner hat Docker-Socket-Zugriff und kann Container spawnen.
|
||||||
echo "FEHLER: RAG API nicht erreichbar unter $RAG_URL"
|
docker run --rm \
|
||||||
echo "Stelle sicher, dass bp-core-rag-service laeuft und breakpilot-network existiert."
|
--network breakpilot-network \
|
||||||
exit 1
|
-v "$(pwd)/scripts:/workspace/scripts:ro" \
|
||||||
fi
|
-e "WORK_DIR=/tmp/rag-ingestion" \
|
||||||
echo "RAG API erreichbar."
|
-e "RAG_URL=http://bp-core-rag-service:8097/api/v1/documents/upload" \
|
||||||
echo ""
|
-e "QDRANT_URL=https://qdrant-dev.breakpilot.ai" \
|
||||||
|
-e "SDK_URL=http://bp-compliance-ai-sdk:8090" \
|
||||||
if [ "$PHASE" = "all" ]; then
|
alpine:3.19 \
|
||||||
bash scripts/ingest-legal-corpus.sh
|
sh -c "
|
||||||
else
|
apk add --no-cache curl bash coreutils > /dev/null 2>&1
|
||||||
bash scripts/ingest-legal-corpus.sh --only "$PHASE"
|
mkdir -p /tmp/rag-ingestion/{pdfs,repos,texts}
|
||||||
fi
|
cd /workspace
|
||||||
|
if [ '$PHASE' = 'all' ]; then
|
||||||
|
bash scripts/ingest-legal-corpus.sh
|
||||||
|
else
|
||||||
|
bash scripts/ingest-legal-corpus.sh --only '$PHASE'
|
||||||
|
fi
|
||||||
|
"
|
||||||
|
|
||||||
echo ""
|
echo ""
|
||||||
echo "=== Ingestion abgeschlossen ==="
|
echo "=== Ingestion abgeschlossen ==="
|
||||||
|
|||||||
Reference in New Issue
Block a user