kube-flannel-rbac.yml - 404 error (not able to install)

724 views Asked by At

I am trying to run this command - kubectl apply -f https://raw.githubusercontent.com/coreos/flannel/master/Documentation/k8s-manifests/kube-flannel-rbac.yml

but it gives following output

solve error - "error: unable to read URL "https://raw.githubusercontent.com/coreos/flannel/master/Documentation/kube-flannel-rbac.yml", server reported 404 Not Found, status code=404"

I am running this on ubuntu on AWS ec2.

1

There are 1 answers

0
norbjd On

You got a 404 simply because that file does not exist anymore on master branch.

You can find the kube-flannel-rbac.yaml in the k8s-old-manifests folder: https://github.com/flannel-io/flannel/blob/v0.22.2/Documentation/k8s-old-manifests/kube-flannel-rbac.yml.

To install it (version v0.22.2), you can:

kubectl apply -f https://raw.githubusercontent.com/flannel-io/flannel/v0.22.2/Documentation/k8s-old-manifests/kube-flannel-rbac.yml

Note that this kube-flannel-rbac.yaml has disappeared since version v0.20.0. This is why you can't find it on master branch, that you're trying to reach. You can find it in older versions, like v0.19.0:

kubectl apply -f https://raw.githubusercontent.com/flannel-io/flannel/v0.19.0/Documentation/k8s-manifests/kube-flannel-rbac.yml

BTW:

  • coreos/flannel has been moved to flannel-io/flannel (but I guess you can still use coreos/flannel in the URL as it will redirect you automatically)
  • be careful to use the manifest corresponding to the Flannel version you're trying to install to avoid surprises