-
Notifications
You must be signed in to change notification settings - Fork 8.1k
Closed
Labels
Description
I am trying to install Ansible in the following environment.
arun@fedora:~/Projects/bingoarun/istio/install/ansible$ kubectl version
Client Version: version.Info{Major:"1", Minor:"10", GitVersion:"v1.10.2", GitCommit:"81753b10df112992bf51bbc2c2f85208aad78335", GitTreeState:"clean", BuildDate:"2018-04-27T09:22:21Z", GoVersion:"go1.9.3", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"10", GitVersion:"v1.10.0", GitCommit:"fc32d2f3698e36b93322a3465f63a14e9f0eaead", GitTreeState:"clean", BuildDate:"2018-03-26T16:44:10Z", GoVersion:"go1.9.3", Compiler:"gc", Platform:"linux/amd64"}
arun@fedora:~/Projects/bingoarun/istio/install/ansible$ ansible --version
ansible 2.5.3
config file = /home/arun/Projects/bingoarun/istio/install/ansible/ansible.cfg
configured module search path = [u'/home/arun/.ansible/plugins/modules', u'/usr/share/ansible/plugins/modules']
ansible python module location = /usr/lib/python2.7/dist-packages/ansible
executable location = /usr/bin/ansible
python version = 2.7.15rc1 (default, Apr 15 2018, 21:51:34) [GCC 7.3.0]
I am passing the cluster_flavor as k8s.
arun@fedora:~/Projects/bingoarun/istio/install/ansible$ ansible-playbook main.yml -e '{"cluster_flavour": "k8s"}' -vvv
When running the playbook, I am getting the following error.
TASK [istio : assert] *******************************************************************************************************************************
fatal: [localhost]: FAILED! => {
"assertion": "vo.stdout >= minimum_cluster_version",
"changed": false,
"evaluated_to": false,
"msg": "Cluster version must be at least 1.7.0"
}
to retry, use: --limit @/home/arun/Projects/bingoarun/istio/install/ansible/main.retry
I tried to run the playbook in debug mode and tried to print the contents of the variable 'vo'
TASK [istio : Extract server version] ***************************************************************************************************************
task path: /home/arun/Projects/bingoarun/istio/install/ansible/istio/tasks/main.yml:22
Using module file /usr/lib/python2.7/dist-packages/ansible/modules/commands/command.py
<127.0.0.1> ESTABLISH LOCAL CONNECTION FOR USER: arun
<127.0.0.1> EXEC /bin/sh -c 'echo ~arun && sleep 0'
<127.0.0.1> EXEC /bin/sh -c '( umask 77 && mkdir -p "` echo /home/arun/.ansible/tmp/ansible-tmp-1528456955.52-107553329050266 `" && echo ansible-tmp-1528456955.52-107553329050266="` echo /home/arun/.ansible/tmp/ansible-tmp-1528456955.52-107553329050266 `" ) && sleep 0'
<127.0.0.1> PUT /home/arun/.ansible/tmp/ansible-local-28063mc3_IW/tmpOhYjri TO /home/arun/.ansible/tmp/ansible-tmp-1528456955.52-107553329050266/command.py
<127.0.0.1> EXEC /bin/sh -c 'chmod u+x /home/arun/.ansible/tmp/ansible-tmp-1528456955.52-107553329050266/ /home/arun/.ansible/tmp/ansible-tmp-1528456955.52-107553329050266/command.py && sleep 0'
<127.0.0.1> EXEC /bin/sh -c '/usr/bin/python2 /home/arun/.ansible/tmp/ansible-tmp-1528456955.52-107553329050266/command.py && sleep 0'
<127.0.0.1> EXEC /bin/sh -c 'rm -f -r /home/arun/.ansible/tmp/ansible-tmp-1528456955.52-107553329050266/ > /dev/null 2>&1 && sleep 0'
changed: [localhost] => {
"changed": true,
"cmd": "kubectl version | sed -En \"s/Server Version.*GitVersion.*v([[:digit:]]\\.[[:digit:]]\\.[[:digit:]]).*/\\1/p\" | tail -1",
"delta": "0:00:00.099051",
"end": "2018-06-08 16:52:35.755299",
"invocation": {
"module_args": {
"_raw_params": "kubectl version | sed -En \"s/Server Version.*GitVersion.*v([[:digit:]]\\.[[:digit:]]\\.[[:digit:]]).*/\\1/p\" | tail -1",
"_uses_shell": true,
"chdir": null,
"creates": null,
"executable": null,
"removes": null,
"stdin": null,
"warn": true
}
},
"rc": 0,
"start": "2018-06-08 16:52:35.656248",
"stderr": "",
"stderr_lines": [],
"stdout": "",
"stdout_lines": []
}
TASK [istio : print vo] *****************************************************************************************************************************
task path: /home/arun/Projects/bingoarun/istio/install/ansible/istio/tasks/main.yml:27
ok: [localhost] => {
"vo": {
"changed": true,
"cmd": "kubectl version | sed -En \"s/Server Version.*GitVersion.*v([[:digit:]]\\.[[:digit:]]\\.[[:digit:]]).*/\\1/p\" | tail -1",
"delta": "0:00:00.099051",
"end": "2018-06-08 16:52:35.755299",
"failed": false,
"rc": 0,
"start": "2018-06-08 16:52:35.656248",
"stderr": "",
"stderr_lines": [],
"stdout": "",
"stdout_lines": []
}
}
TASK [istio : assert] *******************************************************************************************************************************
task path: /home/arun/Projects/bingoarun/istio/install/ansible/istio/tasks/main.yml:31
fatal: [localhost]: FAILED! => {
"assertion": "vo.stdout >= minimum_cluster_version",
"changed": false,
"evaluated_to": false,
"msg": "Cluster version must be at least 1.7.0"
}
to retry, use: --limit @/home/arun/Projects/bingoarun/istio/install/ansible/main.retry
I am using Minikube to set this up.