Check out https://varlock.dev - it uses functions and a plugin system to pull from different backends. But also allows composing values together in whatever way you like, has built in validation, extra protection for secrets, and a ton more.
SecretEnv gets rid of the .env files entirely. Your project lists what it needs by nickname, the actual secrets live in whatever backends your team already uses. Change backend? One line and every repo picks it up.
Both work with any language.
They could actually compose together, varlock can call secretenv to pull from the backends and validate on the top. :)
We piggyback on .env files with a new DSL rather than introducing a new file.
Using plugins that register new functions, you can fetch from many different backends (15 and growing). The main difference if I understand correctly is that the wiring of vars to where those things live does live in committed code, but is totally declarative and safe. It's also incredibly flexible since functions can be written to make things idiomatic for that backend. Keeping that within git makes sense to us, as you ideally want deployments to be immutable.
The other benefit is this gives you a way to manage both sensitive and non-sensitive config - with a single source of truth for validation, types, docs.
I had evaluated fnox. However you have a dependency of encryption/decryption.
So imagine the use case where you need to roll out a password change to 10 repos or offboard an engineer from the team.
In either case, the touch point now becomes 10 repos which need to be co-ordinated against.
Now imagine doing this at scale, you need to migrate password stores entirely. Not that it happens often, however I have been at start-ups where we moved from one cloud provider to another because we gained better discounts on contracts. The password store migration then would be an effort vs just updating 1 line in registry and it resolves.
Similarly user offboarding is handled by IAM permission as well, as soon as the user access is revoked the secret resolution is gone.
Thank you for bringing up fnox and mise. This was something I had evaluated and even written about in the security threat model. :)
Check out https://varlock.dev - it uses functions and a plugin system to pull from different backends. But also allows composing values together in whatever way you like, has built in validation, extra protection for secrets, and a ton more.
Cool, I checked it out and must say varlock's solid, but it's solving different problem.
Varlock makes .env files smarter (validation, types, editor autocomplete, Next.js/Vite hooks).
SecretEnv gets rid of the .env files entirely. Your project lists what it needs by nickname, the actual secrets live in whatever backends your team already uses. Change backend? One line and every repo picks it up.
Both work with any language.
They could actually compose together, varlock can call secretenv to pull from the backends and validate on the top. :)
We piggyback on .env files with a new DSL rather than introducing a new file.
Using plugins that register new functions, you can fetch from many different backends (15 and growing). The main difference if I understand correctly is that the wiring of vars to where those things live does live in committed code, but is totally declarative and safe. It's also incredibly flexible since functions can be written to make things idiomatic for that backend. Keeping that within git makes sense to us, as you ideally want deployments to be immutable.
The other benefit is this gives you a way to manage both sensitive and non-sensitive config - with a single source of truth for validation, types, docs.
[dead]
Thanks for pointing out varlock. Let me go check it out.
The current support for backends include
AWS SSM Parameter Store / AWS Secrets Manager / GCP Secrets Manager / Azure Key Vault / Hashicorp Vault / OpenBao / Cyberark Conjur / 1Password / Doppler / Infisical / Keeper / Cloudflare Workers KV / macOS Keychain / Local File
or... mise and fnox
I had evaluated fnox. However you have a dependency of encryption/decryption.
So imagine the use case where you need to roll out a password change to 10 repos or offboard an engineer from the team.
In either case, the touch point now becomes 10 repos which need to be co-ordinated against.
Now imagine doing this at scale, you need to migrate password stores entirely. Not that it happens often, however I have been at start-ups where we moved from one cloud provider to another because we gained better discounts on contracts. The password store migration then would be an effort vs just updating 1 line in registry and it resolves.
Similarly user offboarding is handled by IAM permission as well, as soon as the user access is revoked the secret resolution is gone.
Thank you for bringing up fnox and mise. This was something I had evaluated and even written about in the security threat model. :)
https://github.com/TechAlchemistX/secretenv/blob/main/docs/s...
I am the maintainer of fnox. This is only true if you use the encryption providers. If you don't, nothing is encrypted obviously.
Your doc also doesn't seem to take into account my preferred way of using it with KMS that solves a lot of the problems mentioned.
[flagged]