diff --git a/book/src/SUMMARY.md b/book/src/SUMMARY.md index f771191..b201bc6 100644 --- a/book/src/SUMMARY.md +++ b/book/src/SUMMARY.md @@ -9,6 +9,7 @@ - [DNS](proxy/dns.md) - [HTTPS](proxy/https.md) - [Services](services.md) +- [Database](database.md) - [Federation](federation.md) - [Haze scripts](scripts.md) - [Xdebug](xdebug.md) diff --git a/book/src/database.md b/book/src/database.md new file mode 100644 index 0000000..bf96761 --- /dev/null +++ b/book/src/database.md @@ -0,0 +1,33 @@ +# Database + +There are 3 ways of accessing the database of a haze instance. + +## CLI + +```bash +haze [filter] db [query] +``` + +Opens the command line client for the database. If a query is specified, it will +be executed. If no query is specified, an interactive shell will be started. + +Example + +``` +haze db 'select fileid, storage, path from oc_filecache' +``` + +## WebUI + +A web UI (based on [DbGate](https://www.dbgate.io/)) is available with every +instance. + +It can be accessed by using `haze open db`, or, if the proxy is setup at +`db.haze.example.com`. + +## External tools + +For usage with external tools, the database connection URL is printed when the +instance is created. + +Details on how to use the connection URL is dependent on the external tool.