Welcome to the Raybeam documentation! This directory contains comprehensive guides for using, deploying, and developing Raybeam.
- API Reference - Complete REST API documentation with examples
- Endpoint specifications
- Authentication and authorization
- Request/response formats
- Common workflows
-
Deployment Guide - Deploy Raybeam in any environment
- Docker and Docker Compose
- Kubernetes deployment
- Binary installation with systemd
- Backup and recovery
- Monitoring and troubleshooting
-
Security Documentation - Security model and best practices
- LDAP authentication and authorization
- Threat model and mitigations
- Compliance considerations (GDPR, SOC 2)
- Security hardening checklist
-
Development Guide - Contributing to Raybeam
- Development environment setup
- Project structure
- Coding standards
- Testing practices
- Pull request process
-
Architecture Documentation - System design and internals
- Component architecture
- Request flows
- Data model
- Technology stack justification
- Scalability considerations
-
Deploy Raybeam:
docker run -d \ -p 8080:8080 \ -v /var/lib/raybeam:/db \ ghcr.io/netresearch/raybeam:latest \ raybeam serve \ -s ldap://ldap.example.com \ -b "DC=example,DC=com" \ -u "readonly" \ -p "password" \ -g "CN=Admins,DC=example,DC=com" -
Upload your SSH key:
curl -u username:password -T ~/.ssh/id_rsa.pub \ http://localhost:8080/users/@me/ssh-keys -
Retrieve keys:
curl http://localhost:8080/users/username/ssh-keys
For detailed deployment instructions, see the Deployment Guide.
docs/
├── README.md # This file - documentation index
├── api.md # REST API reference
├── architecture.md # System design and architecture
├── security.md # Security model and best practices
├── deployment.md # Deployment and operations guide
└── development.md # Development workflow and contributing
- Upload SSH Key: API Reference → Upload SSH Key
- List Keys: API Reference → List SSH Keys
- Delete Keys: API Reference → Delete SSH Keys
- Multi-User Operations: API Reference → Multi-User Operations
- Docker Compose: Deployment Guide → Docker Compose
- Kubernetes: Deployment Guide → Kubernetes
- With Traefik: Deployment Guide → With Traefik
- Backup: Deployment Guide → Backup and Recovery
- LDAP Configuration: Security → LDAP Integration
- TLS Setup: Security → TLS/HTTPS
- Threat Model: Security → Threat Model
- Security Checklist: Deployment Guide → Security Hardening
- Setup Environment: Development Guide → Getting Started
- Project Structure: Development Guide → Project Structure
- Adding Features: Development Guide → Adding New Features
- Running Tests: Development Guide → Testing
Raybeam uses LDAP-based authentication with role-based access control:
- Public: Read-only access to SSH keys (no auth required)
- User: Self-service key management via LDAP credentials
- Admin: Manage keys for any user via LDAP group membership
See Security Documentation for details.
Raybeam uses BoltDB for embedded key-value storage:
- Single file database (
db.bolt) - ACID transactions
- SSH keys stored per user (LDAP DN as key)
- No external database required
See Architecture Documentation for details.
Raybeam provides a REST API with dual response formats:
- text/plain (default): SSH
authorized_keysformat for direct use - application/json: Structured responses for programmatic access
See API Reference for details.
-
Authentication Failures
- Verify LDAP server connectivity
- Check service account credentials
- Validate Base DN configuration
- See: Deployment Guide → Troubleshooting
-
Admin Authorization Issues
- Verify user is member of admin LDAP group
- Check admin group DN matches exactly
- Validate LDAP group membership query
- See: Deployment Guide → Admin Authorization Issues
-
Database Errors
- Check file permissions (should be 0600)
- Verify disk space availability
- Consider restoring from backup
- See: Deployment Guide → Database Issues
For more troubleshooting guidance, see:
┌─────────────────────────────────────────────────────────┐
│ HTTP Client │
│ (curl, scripts, apps) │
└────────────────┬────────────────────────────────────────┘
│ HTTP Basic Auth
▼
┌─────────────────────────────────────────────────────────┐
│ Raybeam Server │
│ ┌──────────────────────────────────────────────────┐ │
│ │ Logger → Auth Middleware → Route Handlers │ │
│ └──────────────────────────────────────────────────┘ │
└─────────┬─────────────────────────────┬─────────────────┘
│ │
▼ ▼
┌───────────────┐ ┌─────────────┐
│ LDAP Server │ │ BoltDB │
│ (Auth) │ │ (Storage) │
└───────────────┘ └─────────────┘
For detailed architecture information, see Architecture Documentation.
Production Deployment Requirements:
- ✅ Deploy behind HTTPS/TLS reverse proxy
- ✅ Use
ldaps://for LDAP connections - ✅ Configure rate limiting
- ✅ Enable access logging and monitoring
- ✅ Implement encrypted backups
- ✅ Restrict file permissions (BoltDB: 0600)
- ✅ Follow principle of least privilege for LDAP service account
For comprehensive security guidance, see Security Documentation.
Expected Performance:
- Read operations: <5ms (BoltDB)
- Write operations: <10ms (BoltDB)
- LDAP authentication: 50-200ms (network dependent)
- Total request time: 100-300ms for authenticated writes
Scalability:
- Single-writer limitation (BoltDB)
- Suitable for <10K operations/second
- Vertical scaling recommended
- Read replicas possible with file replication
For performance details, see Architecture Documentation.
Contributions are welcome! Please read the Development Guide before submitting pull requests.
Quick Start for Contributors:
- Fork the repository
- Create a feature branch:
git checkout -b feature/my-feature - Make changes with tests
- Run tests:
go test ./... - Commit with conventional commit format
- Submit pull request
See Development Guide → Contributing for detailed guidelines.
- Repository: https://github.com/netresearch/raybeam
- Issues: https://github.com/netresearch/raybeam/issues
- Discussions: https://github.com/netresearch/raybeam/discussions
- Container Registry: https://github.com/netresearch/raybeam/pkgs/container/raybeam
- Releases: https://github.com/netresearch/raybeam/releases
Raybeam is released under the MIT License. See LICENSE for details.
- Bug Reports: GitHub Issues
- Feature Requests: GitHub Discussions
- Security Issues: Security Advisories
Need help? Start with the API Reference or Deployment Guide, or open a discussion.