How to use node-vault - 2 common examples

To help you get started, we’ve selected a few node-vault examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github poetapp / frost-api / src / utils / Vault / Vault.ts View on Github external
export function config(options?: Options) {
    this.vault = VaultLib(options)
  }
github opbi / ncm / src / lib / vault.js View on Github external
const setupVaultWithGithubToken = async ({ endpoint }) => {
  const { VAULT_AUTH_GITHUB_TOKEN } = process.env;
  if (!VAULT_AUTH_GITHUB_TOKEN)
    throw Error('VAULT_AUTH_GITHUB_TOKEN not found');

  const vaultClient = vault({ endpoint });

  const res = await vaultClient.githubLogin({
    token: VAULT_AUTH_GITHUB_TOKEN,
  });
  vaultClient.token = res.auth.client_token;

  return vaultClient;
};

node-vault

Javascript client for HashiCorp's Vault

MIT
Latest version published 1 year ago

Package Health Score

57 / 100
Full package analysis

Popular node-vault functions