nixpkgs/nixos/tests/vault.nix
Robert Hensing 530df49d7a
Merge pull request #108411 from hercules-ci/vault-multiple-config-files
vault: Support multiple config files (no secrets in store)
2021-01-24 13:49:06 +01:00

24 lines
650 B
Nix

import ./make-test-python.nix ({ pkgs, ... }:
{
name = "vault";
meta = with pkgs.lib.maintainers; {
maintainers = [ lnl7 ];
};
machine = { pkgs, ... }: {
environment.systemPackages = [ pkgs.vault ];
environment.variables.VAULT_ADDR = "http://127.0.0.1:8200";
services.vault.enable = true;
virtualisation.memorySize = 512;
};
testScript =
''
start_all()
machine.wait_for_unit("multi-user.target")
machine.wait_for_unit("vault.service")
machine.wait_for_open_port(8200)
machine.succeed("vault operator init")
machine.succeed("vault status | grep Sealed | grep true")
'';
})