I'm on the hunt for an existing solution for mutating admission webhooks, ideally in TypeScript or Python, before I dive into writing my own. I've just spent a day trying to set up a Kyverno policy for a complex modification I need to apply to resources before they hit the cluster, but it turned into a fragile mess that doesn't fully work yet. I'm searching for something that handles all the setup without requiring specialized languages, as I'm more comfortable with mainstream ones. Any suggestions would be hugely appreciated!
5 Answers
You should check out Metacontroller. It's flexible and lets you work in the language of your choice, which might be exactly what you need!
Kyverno can work with an external data source, which is what I've done to modify requests. It has its pros and cons for sure, but it could be worth it if you're willing to experiment with it!
If you're open to using Python, have a look at Kopf. It's a simple way to write operators and could potentially meet your requirements, even if it's a bit more than what you're currently looking for.
Have you looked into using CEL? It's the recommended language for scripting with the Kubernetes API server. It might be the solution you're missing out on! Check it out on the Kubernetes docs for mutating admission policy.
I found JSPolicy to be pretty effective. You can run and test it easily with JavaScript, and it sounds like it fits your needs better than Kyverno. Just keep in mind, it seems a bit abandoned, so that might be a concern.

Related Questions
XML Signature Verifier
Voltage Divider Calculator
SSL Certificate Decoder
SQL Formatter
Online Font Playground to Test Google or Custom Fonts
File Hash Generator Online – Get Instant MD5 and SHA-256 Hashes