Skip to main content
CyborgDB can be deployed as a standalone microservice using Docker. This allows you to run a fully self-contained encrypted vector search service on your own infrastructure with minimal setup. The service exposes a REST API for integration with any stack.
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.For quick evaluation, you can generate a temporary demo key using any of the SDKs:
import cyborgdb
print(cyborgdb.get_demo_api_key())
Then use the printed key as your CYBORGDB_API_KEY when starting the service, and as the api_key when connecting with an SDK client.Make sure to keep your API key secure and do not share it publicly.
2

Choose Your Storage Backend (Optional)

The container ships with three storage backends. Skip this step and you get disk (embedded RocksDB) by default — persisted in /app/cyborgdb_data inside the container, which you’ll typically bind to a host volume.
  • Disk (default) — embedded RocksDB. Persistent, no external dependencies.
  • S3 — AWS S3 or any S3-compatible store (MinIO, Cloudflare R2, …). Best for cloud-native and multi-replica deployments.
  • Memory — in-process only, nothing persists across restarts. For tests and ephemeral indexes.
For full details, see the Backing Stores guide.
v0.17 collapsed the storage surface. The previous standalone, postgres, and redis backends and the catch-all CYBORGDB_CONNECTION_STRING are gone — switch standalonedisk and use the new CYBORGDB_DISK_PATH / CYBORGDB_S3_* variables.
3

Pull the Docker Image

The CyborgDB service is available as a Docker image. You can pull it from Docker Hub:
docker pull cyborginc/cyborgdb-service:latest
This image contains everything you need to run the CyborgDB service, including all dependencies and configurations.
4

Run with Docker (Quick Start)

# Minimal — disk is the default; bind the data dir to a host volume
sudo docker run -it --rm --network host \
  -e CYBORGDB_API_KEY=cyborg_your_api_key_here \
  -v cyborgdb_data:/app/cyborgdb_data \
  cyborginc/cyborgdb-service:latest
Inside the container the disk path defaults to /app/cyborgdb_data — the -v mount above is what makes the data survive container recreation.
Platform Differences:
  • Linux uses --network host because Docker runs natively and can directly access the host network
  • macOS uses -p 8000:8000 and host.docker.internal because Docker runs in a VM and needs port mapping
5

Run with Docker Compose (Recommended)

For a reproducible setup, use Docker Compose:
Create a docker-compose.yml file:
services:
  cyborgdb:
    image: cyborginc/cyborgdb-service:latest
    ports:
      - "8000:8000"
    environment:
      - CYBORGDB_API_KEY=${CYBORGDB_API_KEY}
    volumes:
      - cyborgdb_data:/app/cyborgdb_data
      - ./logs:/app/logs

volumes:
  cyborgdb_data:
Then run:
docker-compose up -d
6

Verify Installation

Once the service is running, verify it’s working correctly:Health Check:
curl http://localhost:8000/v1/health
API Documentation: Navigate to http://localhost:8000/v1/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:
VariableDescriptionRequiredExample
CYBORGDB_API_KEYYour CyborgDB API keycyborg_abc123...
CYBORGDB_DB_TYPEStorage backend (memory, disk, s3)❌ (defaults to disk)s3
CYBORGDB_DISK_PATHData directory for disk storage/var/lib/cyborgdb
CYBORGDB_S3_BUCKETBucket name for s3 storageRequired for S3my-bucket
CYBORGDB_S3_REGIONRegion for s3 storageus-east-1
PORTService port8000
SSL_CERT_PATHPath to SSL certificate file/etc/ssl/certs/server.crt
SSL_KEY_PATHPath to SSL private key file/etc/ssl/private/server.key
Without CYBORGDB_DB_TYPE, the service uses disk storage rooted at /app/cyborgdb_data inside the container. For the full list (including S3 credentials and KMS), see the Environment Variables guide.
8

Next Steps

Now that your CyborgDB service is running, you can interact with it using client SDKs:Install Client SDKs:
pip install cyborgdb

REST API Reference

Learn how to use the REST API for direct integration

Python SDK Reference

Learn how to use the Python SDK for direct integration

JS/TS SDK Reference

Learn how to use the JavaScript/TypeScript SDK for direct integration

Go SDK Reference

Learn how to use the Go SDK for direct integration
  • Base Image: python:3.11-slim
  • Python Version: 3.11
  • PyTorch: CPU-optimized for maximum compatibility
  • Docker Image Size: ~1.8GB
  • Platform: linux/amd64, linux/arm64
  • Default Port: 8000
AspectPython ServiceDocker Service
Installationpip installdocker run
DependenciesManaged by pip/condaBundled in container
Resource UsageLower overheadHigher overhead
Environment IsolationPython virtualenvContainer isolation
Deployment ComplexitySimple Python deploymentContainer orchestration
ConfigurationEnvironment variables/filesEnvironment variables
Best ForDevelopment, Python-heavy workflowsProduction, cloud deployment
Both approaches provide identical CyborgDB functionality. Choose based on your deployment preferences and infrastructure requirements.