-
Notifications
You must be signed in to change notification settings - Fork 22
Open
Description
Hi,
I am trying to use appRole auth method as below but when it could not able to read the secret as you can see the below error. What might be the reason of this error or what is the missing point.I can able to read the secret via CLI
| read secret failed: 503 - {"errors":["Vault is sealed"]}
| StatusCodeError: 503 - {"errors":["Vault is sealed"]}
const VaultClient = require("node-vault-client");
const vaultClient = VaultClient.boot("main", {
api: { url: "http://vault:8200" },
auth: {
type: "appRole",
config: { role_id: "5adc1e6c-e686-6461-d3f9-3eade5603208" },
},
});
vaultClient
.read("secret/data/my-app/database")
.then((res) => {
console.log(res);
})
.catch((e) => console.error(e));
/ # vault read secret/data/my-app/database
Key Value
--- -----
refresh_interval 168h
database_password_development xxx
database_username_development xxx
/ # vault read auth/approle/role/my-app/role-id
Key Value
--- -----
role_id 5adc1e6c-e686-6461-d3f9-3eade5603208
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels