Looking to use the Python service? Check out our Python Quickstart Guide.
Overview
The Docker service is ideal for teams looking to self-host CyborgDB in cloud, on-prem, or containerized environments.1
Get an API Key
To use CyborgDB, you need an API key. You can get one from the CyborgDB Admin Dashboard.Make sure to keep your API key secure and do not share it publicly.
2
Choose Your Database Backend
CyborgDB service supports two database backends - choose based on your existing infrastructure:
- PostgreSQL: Compatible with your existing PostgreSQL infrastructure
- Managed services: AWS RDS, Azure Database for PostgreSQL, Google Cloud SQL, DigitalOcean Managed Databases
- Self-hosted PostgreSQL instances
- Redis: Compatible with your existing Redis infrastructure
- Managed services: AWS ElastiCache, Azure Cache for Redis, Google Cloud Memorystore, Redis Cloud
- Self-hosted Redis instances
Make sure you have your chosen database running and accessible before proceeding.
3
Pull the Docker Image
The CyborgDB service is available as a Docker image. You can pull it from Docker Hub:This image contains everything you need to run the CyborgDB service, including all dependencies and configurations.
4
Run with Docker (Quick Start)
Platform Differences:
- Linux uses
--network host
because Docker runs natively and can directly access the host network - macOS uses
-p 8000:8000
andhost.docker.internal
because Docker runs in a VM and needs port mapping
5
Run with Docker Compose (Recommended)
For a complete setup with database included, use Docker Compose:
Create a Then run:
docker-compose.yml
file:6
Verify Installation
Once the service is running, verify it’s working correctly:Health Check:API Documentation:
Navigate to http://localhost:8000/docs to explore the interactive API documentation.You should see a response indicating the service is healthy and ready to accept requests.
7
Advanced Configuration
For production deployments, consider these additional configurations:
Variable | Description | Required | Example |
---|---|---|---|
CYBORGDB_API_KEY | Your CyborgDB API key | ✅ | cyborg_abc123... |
CYBORGDB_DB_TYPE | Database backend type | ✅ | postgres or redis |
CYBORGDB_CONNECTION_STRING | Database connection details | ✅ | See connection formats |
CYBORGDB_VERSION | Service version (optional) | ❌ | 0.11.1 |
PORT | Service port | ❌ | 8000 |
SSL_CERT_PATH | Path to SSL certificate file | ❌ | /etc/ssl/certs/server.crt |
SSL_KEY_PATH | Path to SSL private key file | ❌ | /etc/ssl/private/server.key |
For more information on environment variables, refer to the this guide.
8
Next Steps
Now that your CyborgDB service is running, you can interact with it using client SDKs:Install Client SDKs:
Technical Specifications
Technical Specifications
- Base Image:
continuumio/miniconda3:latest
- Python Version: 3.12
- PyTorch: CPU-optimized for maximum compatibility
- Docker Image Size: ~1.8GB
- Platform: linux/amd64, linux/arm64
- Default Port: 8000
Comparison with Python Service
Comparison with Python Service
Aspect | Python Service | Docker Service |
---|---|---|
Installation | pip install | docker run |
Dependencies | Managed by pip/conda | Bundled in container |
Resource Usage | Lower overhead | Higher overhead |
Environment Isolation | Python virtualenv | Container isolation |
Deployment Complexity | Simple Python deployment | Container orchestration |
Configuration | Environment variables/files | Environment variables |
Best For | Development, Python-heavy workflows | Production, cloud deployment |
Both approaches provide identical CyborgDB functionality. Choose based on your deployment preferences and infrastructure requirements.