A high-speed analytics database engine
295
Hardcharger puts DuckDB 2.0 on the network. Clients connect over Warp SQL, an open HTTP protocol that moves Apache Arrow record batches straight from DuckDB to your application: no gRPC, no Flight, no sidecars. It is the successor to GizmoSQL, rebuilt from scratch for DuckDB 2.0, and it is free and open source (Apache 2.0): no editions, no license keys.
--web-ui): SQL editor, results grid, schema
browser, uploads, sessions and an API page./metrics
endpoint, query profiles, KILL SESSION.HARDCHARGER_* environment variables, or a YAML file.📚 Documentation: https://docs.hardcharger.gizmodata.com 🧑💻 Source and issues: https://github.com/gizmodata/hardcharger
docker run --rm -p 31337:31337 -p 31338:31338 \
-e HARDCHARGER_ADMIN_PASSWORD='change-me' \
gizmodata/hardcharger:latest
Port 31337 speaks Warp SQL (plain HTTP until you give it a certificate); 31338 answers
GET /health for load balancers and orchestrators. The administrator is hardcharger with
the password you set.
Keep the database on a volume and turn on the web UI:
docker run -d --name hardcharger -p 31337:31337 -p 31338:31338 \
-v hardcharger-data:/data \
-e HARDCHARGER_ADMIN_PASSWORD='change-me' \
gizmodata/hardcharger:latest --database /data/analytics.duckdb --web-ui
Then open http://localhost:31337/ui/ and sign in as hardcharger / change-me.
Extensions you INSTALL and persistent secrets live under the container user's home,
/var/lib/hardcharger/.duckdb/, as DuckDB keeps them. To keep them across container
replacements, mount a second volume there (-v hardcharger-home:/var/lib/hardcharger), or
point them at the data volume from the init SQL:
SET extension_directory = '/data/extensions';
SET secret_directory = '/data/secrets';
Command-line client, included in the image (it uses TLS by default; --no-tls for a
server without a certificate):
docker exec -it -e HARDCHARGER_PASSWORD='change-me' hardcharger \
hardcharger --host 127.0.0.1 --no-tls --username hardcharger
One statement, as CSV:
docker exec -e HARDCHARGER_PASSWORD='change-me' hardcharger \
hardcharger --host 127.0.0.1 --no-tls --username hardcharger --csv \
--command "SELECT 42 AS answer, version() AS duckdb"
Python (pip install adbc-driver-hardcharger):
from adbc_driver_hardcharger import dbapi as hardcharger
with hardcharger.connect(uri="hardcharger://localhost?tls=false", username="hardcharger", password="change-me") as conn:
with conn.cursor() as cur:
cur.execute(operation="SELECT 42 AS answer, ? AS greeting", parameters=["hello"])
print(cur.fetch_arrow_table())
hardcharger://host is HTTPS on port 31337; ?tls=false is plain HTTP for local use.
Java: hardcharger-jdbc, one jar for
Java 17+, jdbc:hardcharger://host[:port]. JavaScript:
@gizmodata/hardcharger for Node, browsers,
Deno, Bun and Cloudflare Workers. Anything else: Warp SQL is plain HTTP, so curl
works, and the server describes its API in OpenAPI 3.1 at GET /warp/v1/openapi.json.
Every option is a flag (--read-only), an environment variable (HARDCHARGER_READ_ONLY)
or a key in a YAML file passed with --config (read_only: true). Flags win over the
environment, which wins over the file. docker run --rm gizmodata/hardcharger --help lists
them all. The ones most deployments set:
| Option | Environment variable | What it does |
|---|---|---|
--database PATH | HARDCHARGER_DATABASE | DuckDB database file, or :memory: |
--read-only | HARDCHARGER_READ_ONLY | Open the database read-only |
--admin-username | HARDCHARGER_ADMIN_USERNAME | The administrator's user name (hardcharger) |
--admin-password | HARDCHARGER_ADMIN_PASSWORD | The administrator's password (prefer the variable) |
--web-ui | HARDCHARGER_WEB_UI | Serve the web UI at /ui/ on the server's port |
--tls-cert, --tls-key | HARDCHARGER_TLS_CERT, HARDCHARGER_TLS_KEY | TLS certificate chain and key (PEM); mount them into the container |
--memory-limit | HARDCHARGER_MEMORY_LIMIT | DuckDB's memory limit, e.g. 8GB |
--init-sql-commands-file | HARDCHARGER_INIT_SQL_COMMANDS_FILE | SQL run at startup (ATTACH, INSTALL, secrets, …) |
--secret-key | HARDCHARGER_SECRET_KEY | Key that signs access tokens; set it so tokens survive a restart and work across replicas |
--health-port | HARDCHARGER_HEALTH_PORT | Plaintext port serving only /health (31338; 0 for none) |
--metrics-port | HARDCHARGER_METRICS_PORT | Prometheus /metrics (off by default) |
--log-format, --log-level | HARDCHARGER_LOG_FORMAT, HARDCHARGER_LOG_LEVEL | text or json; debug, info, warning, error |
--trusted-proxies | HARDCHARGER_TRUSTED_PROXIES | CIDRs whose X-Forwarded-For names the client, behind a load balancer |
A YAML file, mounted and passed with --config /etc/hardcharger/hardcharger.yaml:
database: /data/analytics.duckdb
port: 31337
health_port: 31338
web_ui: true
log_level: info
print_queries: true
init_sql_commands_file: /etc/hardcharger/init.sql
Access control (users, roles, grants, row policies, masking), SSO, client certificates, instrumentation and the audit log are covered in the documentation and the README.
latest and X.Y.Z are releases; main and sha-<commit> are development
builds of the newest commit on main that passed every CI gate, built exactly as a
release. Use latest or a version for anything that matters.linux/amd64 and linux/arm64, one multi-architecture tag.hardcharger-server and the hardcharger command-line client under
/opt/hardcharger/bin, on PATH. Both are the release tarballs' binaries, built for
glibc 2.28 with every dependency (DuckDB and its extensions, OpenSSL, Arrow, the web UI)
linked in statically, on ubuntu:24.04 with only CA certificates and time zones added.hardcharger (home and working directory
/var/lib/hardcharger). A volume mounted for the database must be writable by it, or run
the container with --user and a HOME it can write.hardcharger-server; arguments to docker run are its flags. Listens on
0.0.0.0:31337, health on 31338.LICENSE and the third-party notices are in /opt/hardcharger and
/usr/share/doc/hardcharger; hardcharger-server --licenses prints them.ghcr.io/gizmodata/hardcharger.An -adbc variant (X.Y.Z-adbc, latest-adbc) adds 15 native ADBC drivers (BigQuery,
Databricks, Exasol, Flight SQL, SQL Server, MySQL, PostgreSQL, Redshift, Snowflake, Trino,
GizmoSQL, Oracle, Db2, Quack and Hardcharger) with system-wide manifests in
/etc/adbc/drivers, for data movement jobs that run next to the server. See the README's
Docker section for details.
pip install hardcharger runs the server; pip install adbc-driver-hardcharger is the client.Documentation: https://docs.hardcharger.gizmodata.com. Issues and feature requests: https://github.com/gizmodata/hardcharger/issues. Slack: GizmoData Community.
Hardcharger™ and GizmoData™ are trademarks of GizmoData LLC. Apache License 2.0.
Content type
Image
Digest
sha256:1dd551f3a…
Size
79.5 MB
Last updated
5 days ago
docker pull gizmodata/hardcharger