Skip to main content

Contributing to Nebula

Thank you for your interest in contributing to Nebula!

Development Setup

Prerequisites

  • Go 1.24 or later
  • Docker and Docker Compose
  • Node.js 18+ (for UI development)
  • Make

Getting Started

  1. Clone the repository:
git clone https://github.com/nebula/nebula.git
cd nebula
  1. Install dependencies:
go mod download
cd ui/web && bun install
  1. Start the development environment:
make run-local
  1. Build the binaries:
make build

Project Structure

  • cmd/ - Main application entry points
  • platform/ - Control plane code
    • api/ - REST/gRPC API handlers
    • service/ - Business logic
    • storage/ - Storage implementations
    • domain/ - Domain models
  • compute/ - Node agent and runtimes
    • daemon/ - Agent implementation
    • docker/ - Docker manager
    • gpu/ - GPU monitoring
    • runtime/ - Runtime implementations
  • shared/ - Shared utilities
  • ui/web/ - React web dashboard

Coding Guidelines

Go Code

  • Follow standard Go conventions
  • Run make fmt before committing
  • Run make lint to check for issues
  • Add tests for new functionality
  • Keep functions small and focused
  • Document exported functions and types

Testing

# Run all tests
make test

# Run tests with coverage
make test-coverage

Commit Messages

  • Use clear, descriptive commit messages
  • Start with a verb (Add, Fix, Update, etc.)
  • Reference issues when applicable

Example:

Add support for GCP provider

- Implement GCP driver interface
- Add GCE instance provisioning
- Update documentation

Fixes #123

Pull Request Process

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Make your changes
  4. Run tests and linting
  5. Commit your changes
  6. Push to your fork
  7. Open a Pull Request

Code Review

All submissions require review. We use GitHub pull requests for this purpose.

Areas for Contribution

  • Bug Fixes - See Issues
  • New Features - Cloud provider drivers, autoscaling, web UI
  • Documentation - Tutorials, guides, API docs
  • Testing - Increase test coverage, add E2E tests
  • DevOps - CI/CD, Docker images, Helm charts

License

By contributing, you agree that your contributions will be licensed under the Apache License 2.0.