Thing is; nixos has been architected for being declarative from the start. Whilst Kubernetes is a stateful REST API.
Sure you can emulate a declarative view on top of a mutable thing (Think React and virtualdom), but having a declarative core makes declarative deployments easier to manage and more elegant.
E.g. in Kubernetes automatically deleting a resource is still hard; It's hard to figure out when something is not "used" anymore.
In nix, you simply run `nix garbage-collect` and all the things that are not referenced by your declaration are automatically deleted.
Sure you can emulate a declarative view on top of a mutable thing (Think React and virtualdom), but having a declarative core makes declarative deployments easier to manage and more elegant.
E.g. in Kubernetes automatically deleting a resource is still hard; It's hard to figure out when something is not "used" anymore.
In nix, you simply run `nix garbage-collect` and all the things that are not referenced by your declaration are automatically deleted.