Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

All secrets missing if one secret cannot be decrypted #333

Open
SuperSandro2000 opened this issue May 19, 2023 · 2 comments
Open

All secrets missing if one secret cannot be decrypted #333

SuperSandro2000 opened this issue May 19, 2023 · 2 comments

Comments

@SuperSandro2000
Copy link
Contributor

The situation was the following: I added a new secret to a nixos configuration with the sops.secret."some/key" option and the path some/key existed in the secret file but was not encrypted for that machine. When deploying the configuration all secrets where missing, not just the one that failed to decrypt. I think it would be better if sops in such cases would decrypt and create all secrets it can and ignoring the ones it cannot. Or maybe it would be possible to detect this already at build time similar to when the path of a secret does not match.

@Mic92
Copy link
Owner

Mic92 commented May 20, 2023

There is a validateSopsFiles option that is true by default and checks if the key is present in the sops, but we cannot check if machine has the right private key to decrypt at build time.

@SuperSandro2000
Copy link
Contributor Author

I know that behaviour and we haven't changed that.
Also it is obvious that at build time we cannot decrypt the secret but at install time would it be possible to skip the secrets which cannot be decrypted instead of not creating any secrets at all?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants