Hi I am a new bee in Ansible. I am trying to manage and create google cloud properties using ansible. However I am getting SSL related errors while connecting.
I tried 1.. downloading the latest cacert.pem from https://curl.haxx.se/docs/caextract.html and set the variable SSL_CERT_FILE. 2. Downoading cacert from *googleapis.google.com with no success But no success. Could someone please let me know what SSL cert I need to set to get this working ? Playbook details: - hosts: localhost tasks: - name: create instance template gce_instance_template: name: case_mgmt_template size: n1-standard-2 image_family: centos-7-v20170523 state: present project_id: "{{ project_id }}" credentials_file: "{{ credentials_file }}" service_account_email: "{{ service_account_email }}" Error Details: fatal: [localhost]: FAILED! => { "changed": false, "failed": true } MSG: Unexpected response: ([SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:579)). Detail: Traceback (most recent call last): File "/tmp/ansible_M7On7q/ansible_modlib.zip/ansible/module_utils/gcp.py", line 267, in gcp_connect project=creds['project_id']) File "/usr/lib/python2.7/site-packages/apache_libcloud-2.0.0-py2.7.egg/libcloud/compute/drivers/gce.py", line 1795, in __init__ super(GCENodeDriver, self).__init__(user_id, key, **kwargs) File "/usr/lib/python2.7/site-packages/apache_libcloud-2.0.0-py2.7.egg/libcloud/common/base.py", line 948, in __init__ self.connection = self.connectionCls(*args, **conn_kwargs) File "/usr/lib/python2.7/site-packages/apache_libcloud-2.0.0-py2.7.egg/libcloud/compute/drivers/gce.py", line 99, in __init__ credential_file=credential_file, **kwargs) File "/usr/lib/python2.7/site-packages/apache_libcloud-2.0.0-py2.7.egg/libcloud/common/google.py", line 765, in __init__ user_id, key, auth_type, credential_file, scopes, **kwargs) File "/usr/lib/python2.7/site-packages/apache_libcloud-2.0.0-py2.7.egg/libcloud/common/google.py", line 660, in __init__ self.token = self.oauth2_conn.get_new_token() File "/usr/lib/python2.7/site-packages/apache_libcloud-2.0.0-py2.7.egg/libcloud/common/google.py", line 537, in get_new_token return self._token_request(request) File "/usr/lib/python2.7/site-packages/apache_libcloud-2.0.0-py2.7.egg/libcloud/common/google.py", line 368, in _token_request data=data) File "/usr/lib/python2.7/site-packages/apache_libcloud-2.0.0-py2.7.egg/libcloud/common/base.py", line 603, in request headers=headers, stream=stream) File "/usr/lib/python2.7/site-packages/apache_libcloud-2.0.0-py2.7.egg/libcloud/http.py", line 215, in request verify=self.verification File "/usr/lib/python2.7/site-packages/requests/sessions.py", line 461, in request resp = self.send(prep, **send_kwargs) File "/usr/lib/python2.7/site-packages/requests/sessions.py", line 573, in send r = adapter.send(request, **kwargs) File "/usr/lib/python2.7/site-packages/requests/adapters.py", line 431, in send raise SSLError(e, request=request) SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:579) Regards, Sushri -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/921bb704-ee0e-4af1-a10e-79f70adbd44b%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
