1 { system ? builtins.currentSystem
2 , pkgs ? import ../.. { inherit system; }
9 machine.wait_for_unit("ferretdb.service")
10 machine.wait_for_open_port(27017)
11 machine.succeed("mongosh --eval 'use myNewDatabase;' --eval 'db.myCollection.insertOne( { x: 1 } );'")
14 with import ../lib/testing-python.nix { inherit system; };
20 name = "ferretdb-postgresql";
21 meta.maintainers = with lib.maintainers; [ julienmalka ];
28 settings.FERRETDB_HANDLER = "pg";
29 settings.FERRETDB_POSTGRESQL_URL = "postgres://ferretdb@localhost/ferretdb?host=/run/postgresql";
32 systemd.services.ferretdb.serviceConfig = {
33 Requires = "postgresql.service";
34 After = "postgresql.service";
37 services.postgresql = {
39 ensureDatabases = [ "ferretdb" ];
42 ensureDBOwnership = true;
46 environment.systemPackages = with pkgs; [ mongosh ];
53 name = "ferretdb-sqlite";
54 meta.maintainers = with lib.maintainers; [ julienmalka ];
59 services.ferretdb.enable = true;
61 environment.systemPackages = with pkgs; [ mongosh ];