From cf8817117e7993fd2747fd04485e6c2e336d8141 Mon Sep 17 00:00:00 2001 From: iFargle Date: Tue, 15 Aug 2023 13:19:40 +0900 Subject: [PATCH] Add a sops update script --- README.md | 2 ++ home-manager/bash.nix | 4 +++- home-manager/neovim.nix | 1 - 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 591d2033..4b7b14c4 100644 --- a/README.md +++ b/README.md @@ -60,6 +60,8 @@ Repo for nix configuration files 1. To edit a file: cd to `/path/to/nix-files/` and run: * `nix-shell -p sops --run "sops secrets/secret_file.yml"` * New shell alias: `sops secrets/secret_file.yml` +2. When you add a new machine, you must update the secrets files encryption. + * Run `sops-update secrets/secrets.yaml` and commit the change. # Lanzaboote / SecureBoot * Instructions here - [Link](https://git.sysctl.io/Mirrors/lanzaboote/src/branch/master/docs/QUICK_START.md) diff --git a/home-manager/bash.nix b/home-manager/bash.nix index d13c22ee..bd6f2851 100644 --- a/home-manager/bash.nix +++ b/home-manager/bash.nix @@ -13,7 +13,9 @@ sops-edit() { nix-shell -p sops --run "sops $1" } - + sops-update() { + nix-shell -p sops --run "sops updatekeys $1" + } nix-clean-all() { nix-channel --update nix-env -u --always diff --git a/home-manager/neovim.nix b/home-manager/neovim.nix index 00c88265..4586916d 100644 --- a/home-manager/neovim.nix +++ b/home-manager/neovim.nix @@ -78,7 +78,6 @@ set cursorline let g:rainbow_active = 1 - colorscheme gruvbox ''; };