Nix + NixOS
Knowsql offers a package that you can use, or a nixosModule that can be used to configure a systemd service for knowsql.
Flake
Add knowsql to your flake inputs
{
inputs.knowsql = {
url = "github:gdwr/knowsql";
follows = "nixpkgs";
};
# rest of your flake...
}
NixOS Module
Then import the module within your nixosConfiguration.
{
nixosConfigurations.example = {
imports = [
knowsql.nixosModules.knowsql
];
services.knowsql.enable = true;
#services.knowsql = {
# enable = true;
# port = 9001; # Configure the port! make sure to enable the firewall ;)
# data_dir = "/tmp/data"; # Change where the datastore lives.
#};
# rest of your configuration...
}
}
Nix Package
nix run github:gdwr/knowsql
Docker
knowsql provides docker containers built in CI for each tagged version.
These can be found here along with other development images.
Release tags can be found here.
Docker Compose
services:
knowsql:
image: ghcr.io/gdwr/knowsql:latest
ports:
- "2288:2288"
# volumes:
# - ./config.toml:/etc/knowsql/config.toml
Docker
docker run -p 2288:2288 ghcr.io/gdwr/knowsql:latest