HUB
Sign inSign up
surrealdb-enterprise logo

surrealdb/surrealdb-enterprise

By surrealdb

•Updated 10 days ago

A scalable, distributed, collaborative, document-graph database, for the realtime web

Image
0

2.0K

surrealdb/surrealdb-enterprise repository overview

SurrealDB - The database and memory for every agent

Website⁠ · Documentation⁠ · Pricing⁠ · Contact us⁠

⁠What is SurrealDB Enterprise?

SurrealDB Enterprise is the commercially licensed edition of SurrealDB. It is the same database, the same SurrealQL, the same HTTP, WebSocket and GraphQL surfaces, with distributed storage engines and operational tooling added on top.

The image's entrypoint is the Enterprise server binary, so it takes the same commands as the community image⁠. See the features⁠, the documentation⁠, and pricing⁠.

⁠A licence is required

This image does not start without a valid licence. These environment variables control licensing:

VariableMeaning
SURREAL_LICENSE_KEYThe licence key.
SURREAL_LICENSE_KEY_FILEAbsolute path to a file containing the key. Mutually exclusive with the above. Use this when the key arrives as a mounted secret.
SURREAL_LICENSE_FILEFrom 4.0.1. Absolute path to a signed licence file, checked locally with no network access. Mutually exclusive with both key variables.
SURREAL_LICENSE_STATE_PATHAbsolute path for the licence attestation cache. Optional, but recommended with a key: without it, every restart needs the licence API reachable. Put it on a persistent volume. Not used with a licence file.

Keys are validated against keygen.sh⁠ and the response signature is verified offline, so validation never passes through a SurrealDB-operated service. A node that cannot reach the licence API keeps serving for a grace period rather than failing immediately.

Don't have a licence yet? See Get a licence⁠ or talk to us⁠.

⁠Start a server

Start a server in memory, with a root user called root. -e SURREAL_LICENSE_KEY with no value copies the key from your shell, which keeps it out of the command line:

docker run --rm --pull always --name surrealdb -p 8000:8000 \
  -e SURREAL_LICENSE_KEY \
  surrealdb/surrealdb-enterprise:latest \
  start --user root --pass secret

The node validates the key when it starts, so the container needs outbound network access.

⁠Run offline with a licence file

From 4.0.1, if your licence includes offline use, mount the licence file read-only and set SURREAL_LICENSE_FILE:

docker run --rm --pull always --name surrealdb -p 8000:8000 \
  -v "$PWD/license.lic:/license.lic:ro" \
  -e SURREAL_LICENSE_FILE=/license.lic \
  surrealdb/surrealdb-enterprise:latest \
  start --user root --pass secret

See Run offline with a licence file⁠.

⁠Persist data

A single node that persists to disk with the Enterprise SurrealDS⁠ engine. The image runs as a non-root user, so pass --user to let it write to a directory from the host:

mkdir mydata
docker run --rm --pull always --name surrealdb -p 8000:8000 \
  --user $(id -u) \
  -e SURREAL_LICENSE_KEY \
  -v $(pwd)/mydata:/mydata \
  surrealdb/surrealdb-enterprise:latest \
  start --user root --pass secret surrealds:///mydata

On 3.x images, the single-node engine is ds-single:// instead of surrealds://. Every community storage engine also works in the Enterprise image.

⁠Run your first query

There is no shell in the image, so call the binary directly:

docker exec -it surrealdb /surrealdb-enterprise sql -e http://localhost:8000 -u root -p secret --ns main --db main --pretty

⁠Run with Docker Compose

A single node, with the credentials and licence key read from a .env file:

services:
  surrealdb:
    image: surrealdb/surrealdb-enterprise:latest # Consider pinning a version tag
    user: "1000" # A host user that can write to ./mydata
    ports:
      - "8000:8000"
    env_file:
      - .env
    volumes:
      - ./mydata:/mydata
    command: start surrealds:///mydata
# .env
SURREAL_USER=root
SURREAL_PASS=secret # Change this in production
SURREAL_LICENSE_KEY=your-licence-key

⁠Image tags

TagContents
latestThe current stable release.
v4.0.1One exact release. Use a version tag in production.

⁠Support and community

Enterprise customers have a support contract; use it for anything production-affecting. For everything else:

For security issues, email [email protected]⁠ instead of opening a public issue. See our security policy⁠.

⁠License

SurrealDB Enterprise is commercial software, distributed under a licence agreement with SurrealDB. Use of this image requires a valid licence. It is not covered by the Business Source License that applies to the community edition.

For licensing terms, pricing, or a trial, see pricing⁠ or contact us⁠.

Tag summary

Content type

Image

Digest

sha256:205f3b2a2…

Size

87.6 MB

Last updated

10 days ago

docker pull surrealdb/surrealdb-enterprise