mirror of
https://github.com/ryantm/agenix.git
synced 2024-11-25 11:08:30 +03:00
Extend flake install section
This commit is contained in:
parent
6d20bf81f8
commit
1d7fd15690
1 changed files with 25 additions and 2 deletions
27
README.md
27
README.md
|
@ -199,13 +199,14 @@ To install the `agenix` binary:
|
|||
|
||||
#### Install CLI via Flakes
|
||||
|
||||
You don't need to install it,
|
||||
You can run the CLI tool ad-hoc without installing it:
|
||||
|
||||
```ShellSession
|
||||
nix run github:ryantm/agenix -- --help
|
||||
```
|
||||
|
||||
but, if you want to (change the system based on your system):
|
||||
But you can also add it permanently into a [NixOS module](https://nixos.wiki/wiki/NixOS_modules)
|
||||
(replace system "x86_64-linux" with your system):
|
||||
|
||||
```nix
|
||||
{
|
||||
|
@ -213,6 +214,28 @@ but, if you want to (change the system based on your system):
|
|||
}
|
||||
```
|
||||
|
||||
e.g. inside your `flake.nix` file:
|
||||
|
||||
```nix
|
||||
{
|
||||
inputs.agenix.url = "github:ryantm/agenix";
|
||||
# ...
|
||||
|
||||
outputs = { self, nixpkgs, agenix }: {
|
||||
# change `yourhostname` to your actual hostname
|
||||
nixosConfigurations.yourhostname = nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
modules = [
|
||||
# ...
|
||||
{
|
||||
environment.systemPackages = [ agenix.packages.${system}.default ];
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
||||
```
|
||||
|
||||
</details>
|
||||
|
||||
## Tutorial
|
||||
|
|
Loading…
Reference in a new issue