-
Notifications
You must be signed in to change notification settings - Fork 1k
Use with git-filter config - filter.*.clean and filter.*.smudge #1137
Copy link
Copy link
Open
Description
I've been able to integrate sops with git such that files are decrypted/encrypted on checkout/commit. This was achieved like this:
-
Set up git-filter config
git config --local filter.sops-json.clean "sops --input-type json --output-type json --encrypt /dev/stdin" git config --local filter.sops-json.smudge "sops --input-type json --output-type json --decrypt /dev/stdin" git config --local filter.sops-json.required true -
Set up
.gitattributesto pass files through the filter*.json filter=sops-json diff=sops-json -
Have a
.sops.yamlconfiguration with default creation_rules:creation_rules: - kms: arn:aws:kms:...:...:key/2305235902
Checkout and commit work well. Unfortunately the files are always considered changed, I believe because the IV is new on every pass.
Is it necessary for the IV to be ephemeral? Is there a way the random IV could be avoided so this workflow is viable - i.e. so the file isn't always marked as modified by git?
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels