mirror of
https://github.com/juspay/services-flake.git
synced 2024-09-11 20:37:10 +03:00
25 lines
625 B
Nix
25 lines
625 B
Nix
{ pkgs, config, ... }: {
|
|
services.weaviate."weaviate1" = {
|
|
enable = true;
|
|
environment = {
|
|
# To fix the problem with nix failing to run weaviate in sandbox mode
|
|
CLUSTER_ADVERTISE_ADDR = "127.0.0.1";
|
|
};
|
|
};
|
|
|
|
settings.processes.test =
|
|
let
|
|
cfg = config.services.weaviate."weaviate1";
|
|
in
|
|
{
|
|
command = pkgs.writeShellApplication {
|
|
runtimeInputs = [ cfg.package pkgs.curl ];
|
|
text = ''
|
|
curl http://localhost:8080/v1/.well-known/live
|
|
'';
|
|
name = "weaviate-test";
|
|
};
|
|
depends_on."weaviate1".condition = "process_healthy";
|
|
};
|
|
}
|