try again, with puppetforge modules, correctly included now
[mirror/dsa-puppet.git] / 3rdparty / modules / nova / manifests / compute / vmware.pp
1 #
2 # Configure the VMware compute driver for nova.
3 #
4 # === Parameters
5 #
6 # [*host_ip*]
7 #   The IP address of the VMware vCenter server.
8 #
9 # [*host_username*]
10 #   The username for connection to VMware vCenter server.
11 #
12 # [*host_password*]
13 #   The password for connection to VMware vCenter server.
14 #
15 # [*cluster_name*]
16 #   The name of a vCenter cluster compute resource.
17 #
18 # [*api_retry_count*]
19 #   (optional) The number of times we retry on failures,
20 #   e.g., socket error, etc.
21 #   Defaults to 5.
22 #
23 # [*maximum_objects*]
24 #   (optional) The maximum number of ObjectContent data objects that should
25 #   be returned in a single result. A positive value will cause
26 #   the operation to suspend the retrieval when the count of
27 #   objects reaches the specified maximum. The server may still
28 #   limit the count to something less than the configured value.
29 #   Any remaining objects may be retrieved with additional requests.
30 #   Defaults to 100.
31 #
32 # [*task_poll_interval*]
33 #   (optional) The interval in seconds used for polling of remote tasks.
34 #   Defaults to 5.0
35 #
36 # [*use_linked_clone*]
37 #   (optional) Whether to use linked clone strategy while creating VM's.
38 #   Defaults to true.
39 #
40 # [*wsdl_location*]
41 #   (optional) VIM Service WSDL Location e.g
42 #   http://<server>/vimService.wsdl. Optional over-ride to
43 #   default location for bug work-arounds.
44 #   Defaults to None.
45 #
46
47 class nova::compute::vmware(
48   $host_ip,
49   $host_username,
50   $host_password,
51   $cluster_name,
52   $api_retry_count=5,
53   $maximum_objects=100,
54   $task_poll_interval=5.0,
55   $use_linked_clone=true,
56   $wsdl_location=undef
57 ) {
58
59   nova_config {
60     'DEFAULT/compute_driver':      value => 'vmwareapi.VMwareVCDriver';
61     'VMWARE/host_ip':              value => $host_ip;
62     'VMWARE/host_username':        value => $host_username;
63     'VMWARE/host_password':        value => $host_password;
64     'VMWARE/cluster_name':         value => $cluster_name;
65     'VMWARE/api_retry_count' :     value => $api_retry_count;
66     'VMWARE/maximum_objects' :     value => $maximum_objects;
67     'VMWARE/task_poll_interval' :  value => $task_poll_interval;
68     'VMWARE/use_linked_clone':     value => $use_linked_clone;
69   }
70
71   if $wsdl_location {
72     nova_config {
73       'VMWARE/wsdl_location' : value => $wsdl_location;
74     }
75   }
76
77   package { 'python-suds':
78     ensure   => present
79   }
80 }