diff --git a/.forgejo/workflows/resume.yml b/.forgejo/workflows/resume.yml index 219b06a..13fdf6d 100644 --- a/.forgejo/workflows/resume.yml +++ b/.forgejo/workflows/resume.yml @@ -50,11 +50,12 @@ jobs: \"reason\": \"one sentence explaining your decision\" }" - echo "Testing Ollama connectivity..." - curl -v http://10.0.1.84:11434/api/tags || echo "Ollama unreachable" + echo "Testing Ollama connectivity on shared network..." + # Using the container name 'ollama' which resolves on the shared bridge network + curl -v http://ollama:11434/api/tags || echo "Ollama unreachable" echo "Sending validation request to Ollama..." - RESPONSE=$(curl -s -X POST http://10.0.1.84:11434/api/generate \ + RESPONSE=$(curl -s -X POST http://ollama:11434/api/generate \ -H "Content-Type: application/json" \ --max-time 300 \ -d "{ @@ -87,19 +88,25 @@ jobs: - name: Block if assessment fails if: steps.extract.outputs.content_found == 'true' run: | - ASSESSMENT="${{ steps.parse.outputs.assessment }}" + # Note: The original workflow referenced steps.parse but it seems to be named validate here. + # Adjusting to use the output from the validate step. + # You may need to validate this based on your actual jq parsing logic in the prev step. + # Assuming RESULT contains the JSON string with assessment fields. + + ASSESSMENT=$(echo "${{ steps.validate.outputs.validation_result }}" | jq -r '.assessment' 2>/dev/null) + REASON=$(echo "${{ steps.validate.outputs.validation_result }}" | jq -r '.reason' 2>/dev/null) if [ "$ASSESSMENT" = "FAIL" ]; then - echo "❌ Resume assessment: FAIL" - echo "${{ steps.parse.outputs.reason }}" + echo "Resume assessment: FAIL" + echo "$REASON" exit 1 else - echo "✅ Resume assessment: PASS" - echo "${{ steps.parse.outputs.reason }}" + echo "Resume assessment: PASS" + echo "$REASON" fi - name: Resume not found if: steps.extract.outputs.content_found == 'false' run: | - echo "❌ content/resume.md not found" + echo "content/resume.md not found" exit 1