Agenix: Difference between revisions

Use the correct agenix package for the agenix CLI tool
Averymt (talk | contribs)
Add installation subsection about using plugins with the nixos and home-manager modules
 
Line 45: Line 45:
environment.systemPackages = [ inputs.agenix.packages.x86_64-linux.default ];
environment.systemPackages = [ inputs.agenix.packages.x86_64-linux.default ];
</syntaxhighlight>
</syntaxhighlight>
<translate>
=== Adding an age plugin ===
When using an age plugin, such as <code>age-plugin-yubikey</code>, it must be added to <code>age</code>'s <code>$PATH</code>.
</translate>
<syntaxhighlight lang="nix">
age.ageBin = "PATH=$PATH:${lib.makeBinPath [ pkgs.age-plugin-yubikey ]} ${pkgs.age}/bin/age"
</syntaxhighlight>
<translate>
When using the Home Manager module, the plugin can be installed in the user's profile with:
</translate>
<syntaxhighlight lang="nix">
home.packages = [
  pkgs.age-plugin-yubikey
];
</syntaxhighlight>
<translate>
<translate>
== Configuration == <!--T:8-->
== Configuration == <!--T:8-->