Back to Chezmoi

Keeper

assets/chezmoi.io/docs/user-guide/password-managers/keeper.md

2.70.21.4 KB
Original Source

Keeper

chezmoi includes support for Keeper using the Commander CLI to expose data as a template function.

Create a persistent login session as described in the Command CLI documentation.

Passwords can be retrieved with the keeperFindPassword template function, for example:

text
examplePasswordFromPath = {{ keeperFindPassword "$PATH" }}
examplePasswordFromUid = {{ keeperFindPassword "$UID" }}

For retrieving more complex data, use the keeper template function with a UID to retrieve structured data from keeper get or the keeperDataFields template function which restructures the output of keeper get in to a more convenient form, for example:

text
keeperDataTitle = {{ (keeper "$UID").data.title }}
examplePassword = {{ index (keeperDataFields "$UID").password 0 }}

Extra arguments can be passed to the Keeper CLI command by setting the keeper.args variable in chezmoi's config file, for example:

<!-- example-formats -->
toml
[keeper]
    args = ["--config", "/path/to/config.json"]
<!-- /example-formats -->