cloudstack: add timeout to utils

This commit is contained in:
Rene Moser 2015-05-30 11:42:45 +02:00
parent fc807e29c8
commit caf3cf6930
2 changed files with 4 additions and 0 deletions

View file

@ -64,12 +64,14 @@ class AnsibleCloudStack:
api_secret = self.module.params.get('secret_key') api_secret = self.module.params.get('secret_key')
api_url = self.module.params.get('api_url') api_url = self.module.params.get('api_url')
api_http_method = self.module.params.get('api_http_method') api_http_method = self.module.params.get('api_http_method')
api_timeout = self.module.params.get('api_timeout')
if api_key and api_secret and api_url: if api_key and api_secret and api_url:
self.cs = CloudStack( self.cs = CloudStack(
endpoint=api_url, endpoint=api_url,
key=api_key, key=api_key,
secret=api_secret, secret=api_secret,
timeout=api_timeout,
method=api_http_method method=api_http_method
) )
else: else:

View file

@ -64,12 +64,14 @@ class AnsibleCloudStack:
api_secret = self.module.params.get('secret_key') api_secret = self.module.params.get('secret_key')
api_url = self.module.params.get('api_url') api_url = self.module.params.get('api_url')
api_http_method = self.module.params.get('api_http_method') api_http_method = self.module.params.get('api_http_method')
api_timeout = self.module.params.get('api_timeout')
if api_key and api_secret and api_url: if api_key and api_secret and api_url:
self.cs = CloudStack( self.cs = CloudStack(
endpoint=api_url, endpoint=api_url,
key=api_key, key=api_key,
secret=api_secret, secret=api_secret,
timeout=api_timeout,
method=api_http_method method=api_http_method
) )
else: else: