{"action":"created","issue":{"url":"https://api.github.com/repos/ansible/ansible/issues/45528","repository_url":"https://api.github.com/repos/ansible/ansible","labels_url":"https://api.github.com/repos/ansible/ansible/issues/45528/labels{/name}","comments_url":"https://api.github.com/repos/ansible/ansible/issues/45528/comments","events_url":"https://api.github.com/repos/ansible/ansible/issues/45528/events","html_url":"https://github.com/ansible/ansible/issues/45528","id":359282242,"node_id":"MDU6SXNzdWUzNTkyODIyNDI=","number":45528,"title":"vmware_deploy_ovf: Boolean values in properties are not being interpreted properly","user":{"login":"jjahns","id":13657090,"node_id":"MDQ6VXNlcjEzNjU3MDkw","avatar_url":"https://avatars3.githubusercontent.com/u/13657090?v=4","gravatar_id":"","url":"https://api.github.com/users/jjahns","html_url":"https://github.com/jjahns","followers_url":"https://api.github.com/users/jjahns/followers","following_url":"https://api.github.com/users/jjahns/following{/other_user}","gists_url":"https://api.github.com/users/jjahns/gists{/gist_id}","starred_url":"https://api.github.com/users/jjahns/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jjahns/subscriptions","organizations_url":"https://api.github.com/users/jjahns/orgs","repos_url":"https://api.github.com/users/jjahns/repos","events_url":"https://api.github.com/users/jjahns/events{/privacy}","received_events_url":"https://api.github.com/users/jjahns/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-09-12T01:32:54Z","updated_at":"2018-09-12T01:40:02Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"<!--- Verify first that your issue is not already reported on GitHub -->\r\n<!--- Also test if the latest release and devel branch are affected too -->\r\n<!--- Complete *all* sections as described, this form is processed automatically -->\r\n\r\n##### SUMMARY\r\n<!--- Explain the problem briefly below -->\r\nBoolean values cannot be assigned as OVF properties, because the module expects a string 'True|False'\r\n\r\n##### ISSUE TYPE\r\n- Bug Report\r\n\r\n##### COMPONENT NAME\r\n<!--- Write the short name of the module, plugin, task or feature below -->\r\nmodule: vmware_deploy_ovf\r\n##### ANSIBLE VERSION\r\n<!--- Paste verbatim output from \"ansible --version\" between quotes -->\r\n```paste below\r\nansible 2.7.0.dev0\r\n  config file = /etc/ansible/ansible.cfg\r\n  configured module search path = [u'/home/jjahns/.ansible/plugins/modules', u'/usr/share/ansible/plugins/modules']\r\n  ansible python module location = /opt/ansible/lib/python2.7/site-packages/ansible\r\n  executable location = /opt/ansible/bin/ansible\r\n  python version = 2.7.15 (default, Aug 26 2018, 01:25:53) [GCC 5.4.0 20160609]\r\n```\r\n\r\n##### CONFIGURATION\r\n<!--- Paste verbatim output from \"ansible-config dump --only-changed\" between quotes -->\r\n```paste below\r\nCACHE_PLUGIN(/etc/ansible/ansible.cfg) = redis\r\nCACHE_PLUGIN_CONNECTION(/etc/ansible/ansible.cfg) = localhost:6379\r\nCACHE_PLUGIN_TIMEOUT(/etc/ansible/ansible.cfg) = 3600\r\nDEFAULT_GATHERING(/etc/ansible/ansible.cfg) = smart\r\nDEFAULT_MANAGED_STR(/etc/ansible/ansible.cfg) = Ansible managed: {file}\r\nDEFAULT_PRIVATE_KEY_FILE(/etc/ansible/ansible.cfg) = /etc/ansible/cloud.key\r\nDISPLAY_SKIPPED_HOSTS(/etc/ansible/ansible.cfg) = False\r\nHOST_KEY_CHECKING(/etc/ansible/ansible.cfg) = False\r\n```\r\n\r\n##### OS / ENVIRONMENT\r\n<!--- Provide all relevant information below, e.g. target OS versions, network device firmware, etc. -->\r\nAnsible Installed on Ubuntu 16.04 \r\nvSphere 6.5 U2\r\n\r\n##### STEPS TO REPRODUCE\r\n<!--- Describe exactly how to reproduce the problem, using a minimal test-case -->\r\nDeploy any OVF with properties that are boolean using the vmware_deploy_ovf module.\r\n<!--- Paste example playbooks or commands between quotes below -->\r\n```yaml\r\n- vmware_deploy_ovf:\r\n    hostname: '{{ vcenter_hostname }}'\r\n    username: '{{ vcenter_username }}'\r\n    password: '{{ vcenter_password }}'\r\n    ovf: /path/to/ubuntu-16.04-amd64.ovf\r\n    wait_for_ip_address: true\r\n    properties:\r\n      my_boolean_property: True\r\n  delegate_to: localhost\r\n```\r\n\r\n<!--- HINT: You can paste gist.github.com links for larger files -->\r\n\r\n##### EXPECTED RESULTS\r\n<!--- Describe what you expected to happen when running the steps above -->\r\nOVF deploys successfully\r\n\r\n##### ACTUAL RESULTS\r\n<!--- Describe what actually happened. If possible run with extra verbosity (-vvvv) -->\r\n\r\n<!--- Paste verbatim command output between quotes -->\r\n```paste below\r\n(ansible) jjahns@autobot:~/nsx-ansible$ ansible-playbook install-nsx-manager.yml -vvv\r\nansible-playbook 2.7.0.dev0\r\n  config file = /etc/ansible/ansible.cfg\r\n  configured module search path = [u'/home/jjahns/.ansible/plugins/modules', u'/usr/share/ansible/plugins/modules']\r\n  ansible python module location = /opt/ansible/lib/python2.7/site-packages/ansible\r\n  executable location = /opt/ansible/bin/ansible-playbook\r\n  python version = 2.7.15 (default, Aug 26 2018, 01:25:53) [GCC 5.4.0 20160609]\r\nUsing /etc/ansible/ansible.cfg as config file\r\nParsed /etc/ansible/hosts inventory source with ini plugin\r\n\r\nPLAYBOOK: install-nsx-manager.yml *****************************************************************************************************************************\r\n1 plays in install-nsx-manager.yml\r\n\r\nPLAY [nsxmanager[1]] ******************************************************************************************************************************************\r\nMETA: ran handlers\r\n<nsxmgr02> ESTABLISH LOCAL CONNECTION FOR USER: jjahns\r\n<nsxmgr02> EXEC /bin/sh -c 'echo ~jjahns && sleep 0'\r\n<nsxmgr02> EXEC /bin/sh -c '( umask 77 && mkdir -p \"` echo /home/jjahns/.ansible/tmp/ansible-tmp-1536715465.24-50505497465643 `\" && echo ansible-tmp-1536715465.24-50505497465643=\"` echo /home/jjahns/.ansible/tmp/ansible-tmp-1536715465.24-50505497465643 `\" ) && sleep 0'\r\nUsing module file /etc/ansible/roles/nsx-ovf/library/vmware_deploy_ovf.py\r\n<nsxmgr02> PUT /home/jjahns/.ansible/tmp/ansible-local-25399zjv3Z_/tmpsbmSUN TO /home/jjahns/.ansible/tmp/ansible-tmp-1536715465.24-50505497465643/AnsiballZ_vmware_deploy_ovf.py\r\n<nsxmgr02> EXEC /bin/sh -c 'chmod u+x /home/jjahns/.ansible/tmp/ansible-tmp-1536715465.24-50505497465643/ /home/jjahns/.ansible/tmp/ansible-tmp-1536715465.24-50505497465643/AnsiballZ_vmware_deploy_ovf.py && sleep 0'\r\n<nsxmgr02> EXEC /bin/sh -c '/opt/ansible/bin/python /home/jjahns/.ansible/tmp/ansible-tmp-1536715465.24-50505497465643/AnsiballZ_vmware_deploy_ovf.py && sleep 0'\r\n<nsxmgr02> EXEC /bin/sh -c 'rm -f -r /home/jjahns/.ansible/tmp/ansible-tmp-1536715465.24-50505497465643/ > /dev/null 2>&1 && sleep 0'\r\n\r\nTASK [nsx-ovf : deploy nsx appliance] *************************************************************************************************************************\r\ntask path: /etc/ansible/roles/nsx-ovf/tasks/main.yml:2\r\nThe full traceback is:\r\nTraceback (most recent call last):\r\n  File \"/home/jjahns/.ansible/tmp/ansible-tmp-1536715465.24-50505497465643/AnsiballZ_vmware_deploy_ovf.py\", line 113, in <module>\r\n    _ansiballz_main()\r\n  File \"/home/jjahns/.ansible/tmp/ansible-tmp-1536715465.24-50505497465643/AnsiballZ_vmware_deploy_ovf.py\", line 105, in _ansiballz_main\r\n    invoke_module(zipped_mod, temp_path, ANSIBALLZ_PARAMS)\r\n  File \"/home/jjahns/.ansible/tmp/ansible-tmp-1536715465.24-50505497465643/AnsiballZ_vmware_deploy_ovf.py\", line 48, in invoke_module\r\n    imp.load_module('__main__', mod, module, MOD_DESC)\r\n  File \"/tmp/ansible_vmware_deploy_ovf_payload_dNLAer/__main__.py\", line 605, in <module>\r\n  File \"/tmp/ansible_vmware_deploy_ovf_payload_dNLAer/__main__.py\", line 597, in main\r\n  File \"/tmp/ansible_vmware_deploy_ovf_payload_dNLAer/__main__.py\", line 425, in upload\r\n  File \"/tmp/ansible_vmware_deploy_ovf_payload_dNLAer/__main__.py\", line 347, in get_lease\r\n  File \"/opt/python/lib/python2.7/site-packages/pyVmomi/VmomiSupport.py\", line 537, in __setattr__\r\n    CheckField(self._GetPropertyInfo(name), val)\r\n  File \"/opt/python/lib/python2.7/site-packages/pyVmomi/VmomiSupport.py\", line 972, in CheckField\r\n    % (info.name, info.type.__name__, valType.__name__))\r\nTypeError: For \"value\" expected type str, but got bool\r\n\r\nfatal: [nsxmgr02]: FAILED! => {\r\n    \"changed\": false, \r\n    \"module_stderr\": \"Traceback (most recent call last):\\n  File \\\"/home/jjahns/.ansible/tmp/ansible-tmp-1536715465.24-50505497465643/AnsiballZ_vmware_deploy_ovf.py\\\", line 113, in <module>\\n    _ansiballz_main()\\n  File \\\"/home/jjahns/.ansible/tmp/ansible-tmp-1536715465.24-50505497465643/AnsiballZ_vmware_deploy_ovf.py\\\", line 105, in _ansiballz_main\\n    invoke_module(zipped_mod, temp_path, ANSIBALLZ_PARAMS)\\n  File \\\"/home/jjahns/.ansible/tmp/ansible-tmp-1536715465.24-50505497465643/AnsiballZ_vmware_deploy_ovf.py\\\", line 48, in invoke_module\\n    imp.load_module('__main__', mod, module, MOD_DESC)\\n  File \\\"/tmp/ansible_vmware_deploy_ovf_payload_dNLAer/__main__.py\\\", line 605, in <module>\\n  File \\\"/tmp/ansible_vmware_deploy_ovf_payload_dNLAer/__main__.py\\\", line 597, in main\\n  File \\\"/tmp/ansible_vmware_deploy_ovf_payload_dNLAer/__main__.py\\\", line 425, in upload\\n  File \\\"/tmp/ansible_vmware_deploy_ovf_payload_dNLAer/__main__.py\\\", line 347, in get_lease\\n  File \\\"/opt/python/lib/python2.7/site-packages/pyVmomi/VmomiSupport.py\\\", line 537, in __setattr__\\n    CheckField(self._GetPropertyInfo(name), val)\\n  File \\\"/opt/python/lib/python2.7/site-packages/pyVmomi/VmomiSupport.py\\\", line 972, in CheckField\\n    % (info.name, info.type.__name__, valType.__name__))\\nTypeError: For \\\"value\\\" expected type str, but got bool\\n\", \r\n    \"module_stdout\": \"\", \r\n    \"msg\": \"MODULE FAILURE\\nSee stdout/stderr for the exact error\", \r\n    \"rc\": 1\r\n}\r\n\tto retry, use: --limit @/home/jjahns/nsx-ansible/install-nsx-manager.retry\r\n```\r\n"},"comment":{"url":"https://api.github.com/repos/ansible/ansible/issues/comments/420482742","html_url":"https://github.com/ansible/ansible/issues/45528#issuecomment-420482742","issue_url":"https://api.github.com/repos/ansible/ansible/issues/45528","id":420482742,"node_id":"MDEyOklzc3VlQ29tbWVudDQyMDQ4Mjc0Mg==","user":{"login":"ansibot","id":6585283,"node_id":"MDQ6VXNlcjY1ODUyODM=","avatar_url":"https://avatars0.githubusercontent.com/u/6585283?v=4","gravatar_id":"","url":"https://api.github.com/users/ansibot","html_url":"https://github.com/ansibot","followers_url":"https://api.github.com/users/ansibot/followers","following_url":"https://api.github.com/users/ansibot/following{/other_user}","gists_url":"https://api.github.com/users/ansibot/gists{/gist_id}","starred_url":"https://api.github.com/users/ansibot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ansibot/subscriptions","organizations_url":"https://api.github.com/users/ansibot/orgs","repos_url":"https://api.github.com/users/ansibot/repos","events_url":"https://api.github.com/users/ansibot/events{/privacy}","received_events_url":"https://api.github.com/users/ansibot/received_events","type":"User","site_admin":false},"created_at":"2018-09-12T01:40:02Z","updated_at":"2018-09-12T01:40:02Z","author_association":"CONTRIBUTOR","body":"Files identified in the description:\n* [lib/ansible/modules/cloud/vmware/vmware_deploy_ovf.py](https://github.com/ansible/ansible/blob/devel/lib/ansible/modules/cloud/vmware/vmware_deploy_ovf.py)\n\nIf these files are inaccurate, please update the `component name` section of the description or use the `!component` bot command.\n\n[click here for bot help](https://github.com/ansible/ansibullbot/blob/master/ISSUE_HELP.md)\n<!--- boilerplate: components_banner --->"}}
{"actor":{"display_login":"ansibot"}}