Skip to content

Commit

Permalink
debugging vault test
Browse files Browse the repository at this point in the history
  • Loading branch information
johanot committed Oct 16, 2024
1 parent e29304f commit 4857e28
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions nixos/vault-test.nix
Original file line number Diff line number Diff line change
Expand Up @@ -215,6 +215,7 @@ nixos-lib.runTest (
dnsutils
dig
];
environment.RUST_BACKTRACE = "full";
wantedBy = [ "multi-user.target" ];
wants = [ "vault-provision.service" ];
after = [ "vault-provision.service" ];
Expand Down
4 changes: 4 additions & 0 deletions src/vault.rs
Original file line number Diff line number Diff line change
Expand Up @@ -229,6 +229,8 @@ pub async fn login(
let role_id = role_id.trim();
let secret_id = secret_id.trim();

log::info("new client");

let mut client = VaultClient::new(
VaultClientSettingsBuilder::default()
.address(vault_addr.as_str())
Expand All @@ -242,6 +244,8 @@ pub async fn login(
secret_id: secret_id.to_string(),
};

log::info("logging into vault with approle credentials...");

client.login("approle", &applogin).await?;
Ok(client)
}
Expand Down

0 comments on commit 4857e28

Please sign in to comment.