Update ryot key
This commit is contained in:
parent
5c757b251c
commit
6aeaa622d6
2 changed files with 57 additions and 46 deletions
21
flake.nix
21
flake.nix
|
@ -25,18 +25,28 @@
|
|||
echo "Decrypting vars file"
|
||||
sops -d group_vars/all.enc.yml > group_vars/all.yml
|
||||
|
||||
echo "Decrypt inventory file"
|
||||
echo "Decrypting inventory file"
|
||||
sops -d work/inventory.enc.yml > work/inventory.yml
|
||||
'';
|
||||
|
||||
clean_sops = pkgs.writeScriptBin "clean_sops" ''
|
||||
#!${pkgs.runtimeShell}
|
||||
|
||||
echo "Decrypting vars file"
|
||||
sops -d group_vars/all.enc.yml > group_vars/all.yml
|
||||
echo "Deleting vars file"
|
||||
rm group_vars/all.yml
|
||||
|
||||
echo "Decrypt inventory file"
|
||||
sops -d work/inventory.enc.yml > work/inventory.yml
|
||||
echo "Deleting inventory file"
|
||||
rm work/inventory.yml
|
||||
'';
|
||||
|
||||
encrypt_sops = pkgs.writeScriptBin "encrypt_sops" ''
|
||||
#!${pkgs.runtimeShell}
|
||||
|
||||
echo "Crypting vars file"
|
||||
sops -e group_vars/all.yml > group_vars/all.enc.yml
|
||||
|
||||
echo "Crypting inventory file"
|
||||
sops -e work/inventory.yml > work/inventory.enc.yml
|
||||
'';
|
||||
in
|
||||
{
|
||||
|
@ -48,6 +58,7 @@
|
|||
import_pub_gpg
|
||||
init_sops
|
||||
clean_sops
|
||||
encrypt_sops
|
||||
];
|
||||
};
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue