vmware-archive/wardroom

kubeadm token creation fails with permission error

Closed this issue · 0 comments

/kind bug

What steps did you take and what happened:
Ran the following command:

python provision.py -a install -o xenial examples/calico.yml

The kubeadm token creation play fails with the following error:

TASK [generate a kubeadm token] ************************************************************************************************************************************************
fatal: [master1 -> master1]: FAILED! => {"changed": true, "cmd": ["/usr/bin/kubeadm", "token", "create", "--config", "/etc/kubernetes/kubeadm.conf", "--kubeconfig", "/etc/kubernetes/admin.conf"], "delta": "0:00:00.680351", "end": "2019-04-30 12:28:29.203961", "msg": "non-zero return code", "rc": 1, "start": "2019-04-30 12:28:28.523610", 
"stderr": "failed to load admin kubeconfig: open /etc/kubernetes/admin.conf: permission denied", "stderr_lines": ["failed to load admin kubeconfig: open /etc/kubernetes/admin.conf: permission denied"], "stdout": "", "stdout_lines": []}

We need to become: yes in the play.