2

Trying several options to resolve the issue with weave-net (How to fix weave-net CrashLoopBackOff for the second node?), I have decided to try calico instead of weave-net. The documentation for kubernetes tells I need only one or another. The command (as per documentation here https://github.com/projectcalico/calico-containers/tree/master/docs/cni/kubernetes/manifests/kubeadm) fails:

vagrant@vm-master:~$ sudo kubectl create -f https://github.com/projectcalico/calico-containers/blob/master/docs/cni/kubernetes/manifests/kubeadm/calico.yaml
yaml: line 6: mapping values are not allowed in this context

What I am doing wrong? Is it known issue? How can I fix/workaround it?

Community
  • 1
  • 1
Andrew
  • 2,055
  • 2
  • 20
  • 27

2 Answers2

2

You need to reference the raw YAML file in your command, instead of the full GitHub HTML document:

kubectl create -f https://raw.githubusercontent.com/projectcalico/calico-containers/master/docs/cni/kubernetes/manifests/kubeadm/calico.yaml
Zahlex
  • 628
  • 2
  • 8
  • 18
0

Simply replace your HTML URL with raw data URL, it will work.

Suraj Narwade
  • 207
  • 2
  • 6