From 7991d3365071c4bd216a18be9ea7e30702964d83 Mon Sep 17 00:00:00 2001 From: Gabriel Arazas Date: Sat, 11 Dec 2021 13:20:55 +0800 Subject: [PATCH] Add secret files in the public Was initially afraid of how age is secure for the publicly showing secret files (even if encrypted). We'll start with something simple for now. --- README.adoc | 3 +++ secrets/README.adoc | 5 +++++ secrets/archive/borgmatic.json | Bin 0 -> 1847 bytes secrets/archive/password | Bin 0 -> 518 bytes secrets/secrets.nix | 16 ++++++++++++++++ 5 files changed, 24 insertions(+) create mode 100644 secrets/README.adoc create mode 100644 secrets/archive/borgmatic.json create mode 100644 secrets/archive/password create mode 100644 secrets/secrets.nix diff --git a/README.adoc b/README.adoc index 15e8cd70..340c9ba0 100644 --- a/README.adoc +++ b/README.adoc @@ -36,6 +36,7 @@ nixos-config ├── lib/ ├── modules/ ├── pkgs/ +├── secrets/ ├── users/ ├── flake.lock ├── flake.nix @@ -52,6 +53,8 @@ For more information, see the link:./modules/README.adoc[related documentation]. * link:./pkgs/[`./pkgs/`] contains my custom packages. It is exported in the flakes at `outputs.packages` compiled through various systems. +* link:./secrets/[`./secrets/`] contains my secrets managed with link:https://github.com/ryantm/agenix[agenix]. + * link:./users/[`./users/`] contains my link:https://github.com/nix-community/home-manager[home-manager] configurations and modules. It is exported in the flakes at `outputs.homeConfigurations`. For more information, see the link:./users/README.adoc[related documentation]. diff --git a/secrets/README.adoc b/secrets/README.adoc new file mode 100644 index 00000000..aff0d253 --- /dev/null +++ b/secrets/README.adoc @@ -0,0 +1,5 @@ += Secrets +:toc: + +My secret files in public! +This is managed through link:https://github.com/ryantm/agenix[agenix] (thus, uses the link:https://github.com/FiloSottile/age[age encryption tool]). diff --git a/secrets/archive/borgmatic.json b/secrets/archive/borgmatic.json new file mode 100644 index 0000000000000000000000000000000000000000..3e15605832b8ff2a4ccbc9c7f4b0bcf0acfb9365 GIT binary patch literal 1847 zcmV-72gvwgXJsvAZewzJaCB*JZZ2I1|G;dZnL~ja5cP}O-Xe(XgD}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3 zn^F(C1o1^<_Q|4Uf&QjhuLlRmYt{;Ib_-9Hq^i2SUiz822 zuK)f@cd^HB_(o}7_kiGuB%tq=q*bCqfZfOrL3c`=^seH?fDd%Fpe5JP~vhDn6fm~H?Gt?dAJda>lZju z&XH2S6BTgXAc7gkuS&O5_{FcrI=6`s+c*7RfpVGTx6`)@9z9kusLYsZwvyWd@w`N{ l8i>0Zt#31Rv>Jhb7)5M_8oF+sv|r(Q8EJYsBau_;{eo!lFMa?3 literal 0 HcmV?d00001 diff --git a/secrets/archive/password b/secrets/archive/password new file mode 100644 index 0000000000000000000000000000000000000000..fb261cbe7c46f7bb6514f575c1bfa47af0d1fd30 GIT binary patch literal 518 zcmZ9|xr)?a007_x1tD0AW!T1Ih`BbI1Vo%}1{gMmd3by|~1V{}oooWQS5bd!hc5Hh7Yj|chsh&ql2IOyvca4MRD z9q>(aVQ5GCm}-%zk3rGtZWV5Mr4oo%o0|%^U5wgY)g+~5G8M5jMjg(9i&`McU7Dee z9Yda-26~)<;b3Z?xRIwhJC_rt4Nj0lA@aOhmdP@g5H-11C6X>pCrxAV-NA4<61erc zV2^DPifRm5$!O!g*0#=njZ*HoQnQa`O&Yc-V(DZ|a2~h7)2dQBb3(a+E#oW&=AMxu z7>1$1jdyBO)G8ln&U6K5U`9+he=Cl;I$}~q2af%(kJ&&I`M4MDzU&w6-sfA79$u#( z<7dx{OTTWwtAE%lr^u_P{7)qK{^7y1-%ph@XV>n-7vK8f+jrKJ Gmwy2R|FS&* literal 0 HcmV?d00001 diff --git a/secrets/secrets.nix b/secrets/secrets.nix new file mode 100644 index 00000000..af0d9416 --- /dev/null +++ b/secrets/secrets.nix @@ -0,0 +1,16 @@ +let + system1 = + "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIG42LafAFOeh3oYz/cm6FXes0ss59/EOCXpGsYvhpI21"; + + user1 = + "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIMclb6WPpYRoMVqCCzQcG2XQHczB6vaIEDIHqjVsyQJi"; + user2 = + "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIBhrzY7tD0ZiGoA6nnfVxRQVQox0votQ2fuHz78LjNUD"; + user3 = + "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIytwsseYS6kV8ldiUV767C2Gy7okxckdDRW4aA3q/Ku"; + user4 = + "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGtn+t2D7clY1U1rzKcSCBJjNbuJzbRArEiM3soyFcnv"; +in { + "archive/password".publicKeys = [ system1 user3 user4 ]; + "archive/borgmatic.json".publicKeys = [ system1 user3 user4 ]; +}