Contributing to OpenPrime
Thank you for your interest in contributing to OpenPrime! This guide will help you get started.
Ways to Contribute​
- Report bugs - File issues for bugs you encounter
- Suggest features - Propose new functionality
- Improve documentation - Fix typos, add examples, clarify explanations
- Submit code - Fix bugs or implement new features
- Review PRs - Help review pull requests from others
Getting Started​
1. Fork and Clone​
# Fork on GitHub, then clone your fork
git clone https://github.com/YOUR_USERNAME/OpenPrime.git
cd OpenPrime
2. Set Up Development Environment​
# Start all services
cd openprime-local-testing
npm start
# Verify everything is running
npm run health
3. Create a Branch​
git checkout -b feature/your-feature-name
# or
git checkout -b fix/issue-description
Development Workflow​
Code Style​
- Frontend: ESLint + Prettier (configured in
openprime-app/) - Backend: ESLint (configured in
openprime-app-backend/) - Python: Black + isort (for Injecto service)
# Frontend linting
cd openprime-app
npm run lint
npm run lint:fix
# Backend linting
cd openprime-app-backend
npm run lint
Running Tests​
# Frontend tests
cd openprime-app
npm test
# Backend tests
cd openprime-app-backend
npm test
Making Changes​
- Write tests first when adding new functionality
- Follow existing patterns in the codebase
- Keep commits focused - one logical change per commit
- Update documentation if changing behavior
Pull Request Process​
Before Submitting​
- All tests pass locally
- Code follows project style guidelines
- Documentation is updated (if needed)
- Commit messages are clear and descriptive
- Branch is up to date with
main
PR Template​
When creating a PR, include:
## Summary
Brief description of changes
## Changes
- Change 1
- Change 2
## Testing
How to test these changes
## Screenshots (if applicable)
Before/after screenshots for UI changes
## Related Issues
Fixes #123
Review Process​
- Automated checks run on all PRs
- Maintainer review required before merge
- Address feedback promptly
- Squash and merge is preferred
Project Structure​
OpenPrime/
├── openprime-app/ # React frontend
├── openprime-app-backend/ # Express.js API
├── openprime-infra-templates/ # Terraform/Helm templates
├── openprime-local-testing/ # Docker orchestration
├── openprime-documentation/ # This documentation
├── Injecto/ # Python template processor
└── StateCraft/ # Terraform state manager
Key Files​
| File | Purpose |
|---|---|
openprime-app/src/config/servicesConfig.js | Service definitions |
openprime-app-backend/src/routes/ | API endpoints |
openprime-infra-templates/templates/ | Infrastructure templates |
Adding New Features​
Adding a Cloud Service​
- Define schema in
servicesConfig.js - Add provider mapping in
providersConfig.js - Create template in
openprime-infra-templates/templates/ - Add tests for new functionality
- Update documentation
Adding a Helm Chart​
- Add chart definition to
helmChartsConfig.js - Include default values
- Test with the wizard flow
- Document configuration options
Code of Conduct​
We follow the Contributor Covenant. Please:
- Be respectful - Treat everyone with respect
- Be constructive - Provide helpful feedback
- Be inclusive - Welcome newcomers
- Be collaborative - Work together effectively
Getting Help​
- GitHub Discussions - Ask questions and share ideas
- Discord - Real-time chat with the community
- Issues - Report bugs or request features
Recognition​
Contributors are recognized in:
- Release notes for significant contributions
- The Contributors section on GitHub
- Our community showcase
Thank you for making OpenPrime better!