1.4.0 • Public • Published

Project Logo

Vault Generator

Report Bug · Request Feature

Table of Contents
  1. About
  2. Getting Started
  3. Usage
  4. Contributing
  5. License
  6. Contact

npm version


Simple YAML Generator using local saved JSON template to facilitate and speed up the creation of new vaults within a project.


This section covers the tools and packages used for the project,

  • NodeJS
  • inquirer
    • For interactive shell
  • js-yaml
    • To convert the generated JSON to YAML
  • ansible-vault
    • To encrypt the strings

Getting Started


  • NodeJS


npm install -g @yetanothertool/vault


The template

You can look at tests/vault.json for a template example. and the tests/decrypt.yml contains an example to unvault the values when using the string approach.

Documentation regarding the YAML Format generated: https://docs.ansible.com/ansible/latest/collections/community/aws/aws_ssm_parameter_store_module.html

For Version > 1.3.0:

  • Added new option for the templates (type)
  • Support new types with inquirer
    • input
    • editor
    • list
    • checkbox
    • password

Create new template

This command let you attach a .json template to an alias.

yat-vault create

Create Template

Generate vault from template

To prepare the whole file

The data is generated unecrypted, it is up to you to encrypt the whole file.

yat-vault generate

Ansible Vault File

To encrypt the value as string

It uses the ansible-vault npm package to encrypt each values.

yat-vault generate-string

Ansible Vault String Ansible Vault String v1.3.0

Passing the vault password with environment variable

export VAULT_PASS="12345"


  1. Create a Feature Branch
  2. Commit your changes
  3. Push your changes
  4. Create a PR
Working with your local branch

Branch Checkout:

git checkout -b <feature|fix|release|chore|hotfix>/prefix-name

Your branch name must starts with [feature|fix|release|chore|hotfix] and use a / before the name; Use hyphens as separator; The prefix correspond to your Kanban tool id (e.g. abc-123)

Keep your branch synced:

git fetch origin
git rebase origin/master

Commit your changes:

git add .
git commit -m "<feat|ci|test|docs|build|chore|style|refactor|perf|BREAKING CHANGE>: commit message"

Follow this convention commitlint for your commit message structure

Push your changes:

git push origin <feature|fix|release|chore|hotfix>/prefix-name


git checkout -b release/v1.15.5
git checkout -b feature/abc-123-something-awesome
git checkout -b hotfix/abc-432-something-bad-to-fix
git commit -m "docs: added awesome documentation"
git commit -m "feat: added new feature"
git commit -m "test: added tests"


Distributed under the MIT License. See LICENSE for more information.


Package Sidebar


npm i @yetanothertool/vault

Weekly Downloads






Unpacked Size

16.2 kB

Total Files


Last publish


  • tgingras