Kaybarax/Standards-Based-Development-MCP-Server
If you are the rightful owner of Standards-Based-Development-MCP-Server and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.
The Standards-Based Development MCP Server is designed to enforce best practices throughout the software development lifecycle, providing a suite of tools for code quality, testing, and deployment.
Standards-Based Development MCP Server
An MCP (Model Context Protocol) server that enforces Standards-Based Development (SBD) throughout the development lifecycle. This server provides tools for code formatting, linting, testing, Docker operations, security scanning, documentation generation, and image publishing.
Features
- Code Formatting: Format code using Prettier with configurable rules
- Code Linting: Lint code using project-specific tools (ESLint, Flake8, etc.)
- Testing: Execute test suites with coverage reporting
- Docker Operations: Build and run Docker containers
- Security Scanning: Perform SAST/SCA scans using Bandit and other tools
- Documentation: Auto-generate project documentation
- Publishing: Tag and push Docker images to registries
Installation
Using Docker (Recommended)
docker pull yourorg/standards-based-development-mcp
From Source
git clone https://github.com/yourorg/standards-based-development-mcp.git
cd standards-based-development-mcp
pip install -r requirements.txt
Usage
Running the Server
Docker
docker run -i yourorg/standards-based-development-mcp
Local Development
python src/server.py
Development with Hot Reload
docker-compose up sbd-mcp-dev
Available Tools
The server exposes the following MCP tools:
- formatCode - Format code using Prettier
- lintCode - Run project-specific linting
- runTests - Execute test suites with coverage
- dockerBuild - Build Docker images
- dockerRun - Run containers in development mode
- scanSecurity - Perform security scans
- generateDocs - Generate project documentation
- publishImage - Publish Docker images to registries
Example JSON-RPC Calls
Format Code
{
"jsonrpc": "2.0",
"method": "tools/call",
"id": 1,
"params": {
"name": "formatCode",
"arguments": {
"code": "const x=1;",
"filePath": "example.js"
}
}
}
Run Tests
{
"jsonrpc": "2.0",
"method": "tools/call",
"id": 2,
"params": {
"name": "runTests",
"arguments": {
"types": ["unit", "integration"]
}
}
}
Development
Setup Development Environment
- Clone the repository:
git clone https://github.com/yourorg/standards-based-development-mcp.git
cd standards-based-development-mcp
- Install dependencies:
pip install -r requirements.txt
npm install -g prettier
- Run tests:
pytest
- Build Docker image:
docker build -t sbd-mcp .
Project Structure
standards-based-development-mcp/
āāā Dockerfile
āāā docker-compose.yml
āāā .prettierrc
āāā .prettierignore
āāā pytest.ini
āāā requirements.txt
āāā src/
ā āāā server.py # Main MCP server with all tools
ā āāā tools/ # Future: modular tool implementations
āāā tests/
ā āāā unit/ # Unit tests
ā āāā integration/ # Integration tests
ā āāā e2e/ # End-to-end tests
āāā .github/
ā āāā workflows/
ā āāā ci.yml # CI/CD pipeline
āāā README.md
Contributing
- Fork the repository
- Create a feature branch:
git checkout -b feature-name
- Make your changes and add tests
- Ensure all tests pass:
pytest
- Format code:
prettier --write .
- Commit your changes:
git commit -am 'Add feature'
- Push to the branch:
git push origin feature-name
- Create a Pull Request
CI/CD Pipeline
The project includes a comprehensive CI/CD pipeline that:
- Runs code formatting checks with Prettier
- Performs linting with Flake8
- Executes unit and integration tests
- Builds Docker images
- Runs end-to-end tests
- Publishes images to Docker Hub (on main branch)
Configuration
Prettier Configuration
The project uses a .prettierrc
configuration for consistent code formatting:
{
"printWidth": 120,
"tabWidth": 2,
"useTabs": false,
"semi": true,
"singleQuote": true,
"trailingComma": "all"
}
Test Configuration
Tests are configured via pytest.ini
with coverage reporting and multiple test types (unit, integration, e2e, regression).
Security
- Input validation and sanitization
- OWASP best practices
- Regular dependency updates
- Security scanning with Bandit
- Container security scanning
License
MIT License - see LICENSE file for details.
Support
For issues and questions:
- Create an issue on GitHub
- Check the documentation in the
docs/
directory - Review the CI/CD logs for troubleshooting