When changing key ordering to prioritize a decryption key over others (age key over password-protected ssh private key), sops updatekeys exit with "File already up to date" message.
updatekeys should update the encryption order of the file, since sops decrypt decrypt the file in the encryption order, rather than in the .sops.yaml key declaration order.
For example, updating .sops.yaml from:
key_groups: &encryption-keys
- age:
- &user_ssh_id ssh-ed25519 rtensaensuurestntreunesaruxxxxxxxxxxxx user@domain.com
- &user_sops_age age1xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
creation_rules:
- path_regex: secrets/.+$
key_groups: *encryption-keys
to
key_groups: &encryption-keys
- age:
- &user_sops_age age1xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
- &user_ssh_id ssh-ed25519 rtensaensuurestntreunesaruxxxxxxxxxxxx user@domain.com
creation_rules:
- path_regex: secrets/.+$
key_groups: *encryption-keys
When changing key ordering to prioritize a decryption key over others (age key over password-protected ssh private key),
sops updatekeysexit with "File already up to date" message.updatekeysshould update the encryption order of the file, sincesops decryptdecrypt the file in the encryption order, rather than in the.sops.yamlkey declaration order.For example, updating .sops.yaml from:
to