As with all things mathworks, migrating away from simulink to alternatives isn't an easy ride. Just having an alternative to Embedded Coder to generate code in another (safer) language proved just too much years ago...
Codex via codex-cli used to be pretty about knowing whether it was in powershell. Think they might have changed the system prompt or something because it’s usually generating powershell on the first attempt.
Sometimes it tries to use shell stuff (especially for redirection), but that’s way less common rn.
Big question is which feature subset you want to replicate.
Kubernetes means everything to everyone. At its core, I think it’s being able to read/write distributed state (which doesn’t need to be etcd) and being able for all the components (especially container hosts) to follow said state. But the ecosystem has expanded significantly beyond that.