xtruder / kubenix

Replaced by https://github.com/hall/kubenix
MIT License
300 stars 34 forks source link

Wrong version for ClusterRoleBinding #6

Closed MostAwesomeDude closed 1 year ago

MostAwesomeDude commented 5 years ago

I made a ClusterRoleBinding object and tried to send it to a 1.11.5 cluster. I get this error:

error: unable to recognize no matches for kind "ClusterRoleBinding" in version "rbac.authorization.k8s.io/v1alpha1"

This is reproducible across four major k8s vendors, all using 1.11.x clusters. On all clusters, the same fix works:

sed -e s/alpha/beta/ </nix/store/….json >fixed.json
kubectl apply -f fixed.json
MostAwesomeDude commented 5 years ago

To give an example of the problematic object:

{
  "apiVersion": "rbac.authorization.k8s.io/v1alpha1",
  "kind": "ClusterRoleBinding",
  "metadata": {
    "labels": {
      "kubenix/build": "4674e9958afd40b743c693008c0952329d3101cc"
    },
    "name": "tahoe-external-view"
  },
  "roleRef": {
    "apiGroup": "rbac.authorization.k8s.io",
    "kind": "ClusterRole",
    "name": "view"
  },
  "subjects": [
    {
      "kind": "ServiceAccount",
      "name": "tahoe-external",
      "namespace": "default"
    }
  ]
}
offlinehacker commented 5 years ago

Okay will take a look into that.

Just to let you know, kubenix is in a progress of major refactoring, that will implement all ideas and fix all issues we had at @gatehubnet and make it generally available. Details and progress are in this issue: https://github.com/xtruder/kubenix/issues/9

Let's finally finish this :muscle:

offlinehacker commented 1 year ago

This repo has been deprecated, since I stopped maintaining it some time ago. There is a fork maintained by @hall available at https://github.com/hall/kubenix, that has better documentation and looks like a way further.