FROM node:20-alpine # Install necessary packages RUN apk add --no-cache git bash # Create test directory WORKDIR /test # Copy package.json to test npm install COPY package.json . # Test installing the alpha version RUN npm install -g claude-flow@2.0.0-alpha.37 # Test the wrapper script COPY scripts/ruv-swarm-safe.js /usr/local/lib/node_modules/claude-flow/scripts/ # Create a test script RUN echo '#!/bin/bash\n\ echo "Testing claude-flow MCP server..."\n\ claude-flow mcp start &\n\ sleep 5\n\ echo "MCP server test completed"\n\ pkill -f "claude-flow mcp"\n\ echo "\nTesting ruv-swarm safe wrapper..."\n\ timeout 10s node /usr/local/lib/node_modules/claude-flow/scripts/ruv-swarm-safe.js || true\n\ echo "\nAll tests completed"' > test.sh && chmod +x test.sh CMD ["./test.sh"]