Skip to content

Helper for creating a Vault plugin directory in Nix

License

Notifications You must be signed in to change notification settings

256lights/vault-plugin-directory.nix

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Nix helper for creating a Vault plugin directory

This repository contains a Nix flake with a single function: lib.mkPluginDirectory. This function takes in the following parameter attribute set:

{
  pkgs :: nixpkgs;
  plugins :: [ plugin set (see below) ];
}

A plugin set is defined as:

{
  binary :: derivation;
  [ type :: "secret" | "auth" | "database"; ]
  [ pname :: string; ]
  [ version :: string; ]
}

mkPluginDirectory will return a derivation with a libexec/vault-plugins directory containing all the listed plugins as well as a bin/register-vault-plugins script that will register all the plugins using the Vault CLI.

Example

vault-plugin-directory.lib.mkPluginDirectory {
  inherit pkgs;
  plugins = [
    { binary = my-vault-secret-plugin; }
  ];
}

License

Apache 2.0

About

Helper for creating a Vault plugin directory in Nix

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published