summaryrefslogtreecommitdiff
path: root/modules/common/agenix.nix
diff options
context:
space:
mode:
authorm4siri <git@m4siri.com>2025-11-23 10:36:43 +0545
committerm4siri <git@m4siri.com>2025-11-23 10:36:56 +0545
commit3424cfd40c046c038df0335212e8000ebd473602 (patch)
treefc800399450284e77be346311952968591a5534e /modules/common/agenix.nix
repo init
Diffstat (limited to 'modules/common/agenix.nix')
-rw-r--r--modules/common/agenix.nix21
1 files changed, 21 insertions, 0 deletions
diff --git a/modules/common/agenix.nix b/modules/common/agenix.nix
new file mode 100644
index 0000000..189f80e
--- /dev/null
+++ b/modules/common/agenix.nix
@@ -0,0 +1,21 @@
+{
+ config,
+ lib,
+ pkgs,
+ ...
+}: let
+ inherit (lib) mkAliasOptionModule mkIf;
+in {
+ imports = [(mkAliasOptionModule ["secrets"] ["age" "secrets"])];
+
+ age.identityPaths = [
+ "/root/.ssh/id"
+ ];
+
+ environment = {
+ shellAliases.ragenix = "ragenix --identity ~/.ssh/id";
+ systemPackages = [
+ pkgs.ragenix
+ ];
+ };
+}