nix-files/pkgs/additional/sane-scripts/src/sane-secrets-update-keys

9 lines
306 B
Plaintext
Executable File

#!/usr/bin/env nix-shell
#!nix-shell -i bash -p coreutils-full -p findutils -p sops
# after modifying .sops.yaml, run this to re-encode all secrets to the new keys
# pass the base directory (under which *everything* is a secret) as argument
for i in $(find "$1" -print)
do
yes | sops updatekeys "$i"
done