@pulumi/vsphere 4.16.2 → 4.16.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/computeCluster.d.ts +137 -67
- package/computeCluster.js +92 -46
- package/computeCluster.js.map +1 -1
- package/computeClusterHostGroup.d.ts +45 -25
- package/computeClusterHostGroup.js +21 -13
- package/computeClusterHostGroup.js.map +1 -1
- package/computeClusterVmAffinityRule.d.ts +32 -20
- package/computeClusterVmAffinityRule.js +20 -14
- package/computeClusterVmAffinityRule.js.map +1 -1
- package/computeClusterVmAntiAffinityRule.d.ts +40 -13
- package/computeClusterVmAntiAffinityRule.js +28 -7
- package/computeClusterVmAntiAffinityRule.js.map +1 -1
- package/computeClusterVmDependencyRule.d.ts +32 -24
- package/computeClusterVmDependencyRule.js +20 -18
- package/computeClusterVmDependencyRule.js.map +1 -1
- package/computeClusterVmGroup.d.ts +32 -23
- package/computeClusterVmGroup.js +8 -11
- package/computeClusterVmGroup.js.map +1 -1
- package/computeClusterVmHostRule.d.ts +36 -26
- package/computeClusterVmHostRule.js +24 -20
- package/computeClusterVmHostRule.js.map +1 -1
- package/configurationProfile.d.ts +88 -0
- package/configurationProfile.js +88 -0
- package/configurationProfile.js.map +1 -1
- package/contentLibrary.d.ts +6 -4
- package/contentLibrary.js +3 -1
- package/contentLibrary.js.map +1 -1
- package/contentLibraryItem.d.ts +3 -2
- package/contentLibraryItem.js +3 -2
- package/contentLibraryItem.js.map +1 -1
- package/customAttribute.d.ts +2 -3
- package/customAttribute.js +2 -3
- package/customAttribute.js.map +1 -1
- package/datacenter.d.ts +18 -8
- package/datacenter.js +4 -3
- package/datacenter.js.map +1 -1
- package/datastoreCluster.d.ts +37 -25
- package/datastoreCluster.js +10 -10
- package/datastoreCluster.js.map +1 -1
- package/datastoreClusterVmAntiAffinityRule.d.ts +37 -22
- package/datastoreClusterVmAntiAffinityRule.js +13 -13
- package/datastoreClusterVmAntiAffinityRule.js.map +1 -1
- package/distributedPortGroup.d.ts +19 -9
- package/distributedPortGroup.js +7 -6
- package/distributedPortGroup.js.map +1 -1
- package/distributedVirtualSwitch.d.ts +27 -10
- package/distributedVirtualSwitch.js +3 -4
- package/distributedVirtualSwitch.js.map +1 -1
- package/dpmHostOverride.d.ts +21 -16
- package/dpmHostOverride.js +9 -10
- package/dpmHostOverride.js.map +1 -1
- package/drsVmOverride.d.ts +22 -17
- package/drsVmOverride.js +10 -11
- package/drsVmOverride.js.map +1 -1
- package/entityPermissions.d.ts +58 -0
- package/entityPermissions.js +58 -0
- package/entityPermissions.js.map +1 -1
- package/file.d.ts +15 -0
- package/file.js +15 -0
- package/file.js.map +1 -1
- package/folder.d.ts +37 -19
- package/folder.js +7 -10
- package/folder.js.map +1 -1
- package/getComputeCluster.d.ts +35 -19
- package/getComputeCluster.js +24 -10
- package/getComputeCluster.js.map +1 -1
- package/getCustomAttribute.d.ts +10 -6
- package/getCustomAttribute.js +10 -6
- package/getCustomAttribute.js.map +1 -1
- package/getDatacenter.d.ts +10 -6
- package/getDatacenter.js +10 -6
- package/getDatacenter.js.map +1 -1
- package/getDatastore.d.ts +22 -16
- package/getDatastore.js +12 -8
- package/getDatastore.js.map +1 -1
- package/getDatastoreCluster.d.ts +24 -10
- package/getDatastoreCluster.js +20 -6
- package/getDatastoreCluster.js.map +1 -1
- package/getDistributedVirtualSwitch.d.ts +25 -19
- package/getDistributedVirtualSwitch.js +12 -8
- package/getDistributedVirtualSwitch.js.map +1 -1
- package/getHost.d.ts +23 -13
- package/getHost.js +8 -4
- package/getHost.js.map +1 -1
- package/getNetwork.d.ts +12 -8
- package/getNetwork.js.map +1 -1
- package/getOvfVmTemplate.d.ts +276 -0
- package/getOvfVmTemplate.js +276 -0
- package/getOvfVmTemplate.js.map +1 -1
- package/getResourcePool.d.ts +38 -26
- package/getResourcePool.js +16 -8
- package/getResourcePool.js.map +1 -1
- package/getTag.d.ts +14 -10
- package/getTag.js +14 -10
- package/getTag.js.map +1 -1
- package/getTagCategory.d.ts +8 -4
- package/getTagCategory.js +8 -4
- package/getTagCategory.js.map +1 -1
- package/getVappContainer.d.ts +16 -6
- package/getVappContainer.js +6 -2
- package/getVappContainer.js.map +1 -1
- package/getVirtualMachine.d.ts +58 -36
- package/getVirtualMachine.js +10 -6
- package/getVirtualMachine.js.map +1 -1
- package/getVmfsDisks.d.ts +12 -4
- package/getVmfsDisks.js +6 -2
- package/getVmfsDisks.js.map +1 -1
- package/haVmOverride.d.ts +8 -10
- package/haVmOverride.js +8 -10
- package/haVmOverride.js.map +1 -1
- package/host.d.ts +54 -80
- package/host.js +54 -80
- package/host.js.map +1 -1
- package/hostPortGroup.d.ts +21 -11
- package/hostPortGroup.js +8 -4
- package/hostPortGroup.js.map +1 -1
- package/hostVirtualSwitch.d.ts +21 -17
- package/hostVirtualSwitch.js +9 -11
- package/hostVirtualSwitch.js.map +1 -1
- package/nasDatastore.d.ts +48 -35
- package/nasDatastore.js +9 -8
- package/nasDatastore.js.map +1 -1
- package/package.json +2 -2
- package/resourcePool.d.ts +31 -7
- package/resourcePool.js +13 -1
- package/resourcePool.js.map +1 -1
- package/role.d.ts +31 -2
- package/role.js +31 -2
- package/role.js.map +1 -1
- package/storageDrsVmOverride.d.ts +40 -17
- package/storageDrsVmOverride.js +19 -8
- package/storageDrsVmOverride.js.map +1 -1
- package/tag.d.ts +16 -15
- package/tag.js +16 -15
- package/tag.js.map +1 -1
- package/tagCategory.d.ts +2 -3
- package/tagCategory.js +2 -3
- package/tagCategory.js.map +1 -1
- package/types/input.d.ts +5 -3
- package/types/output.d.ts +5 -3
- package/vappContainer.d.ts +21 -12
- package/vappContainer.js +0 -3
- package/vappContainer.js.map +1 -1
- package/vappEntity.d.ts +14 -11
- package/vappEntity.js +2 -5
- package/vappEntity.js.map +1 -1
- package/virtualDisk.d.ts +18 -10
- package/virtualDisk.js +9 -7
- package/virtualDisk.js.map +1 -1
- package/virtualMachine.d.ts +1102 -10
- package/virtualMachine.js +1056 -6
- package/virtualMachine.js.map +1 -1
- package/virtualMachineSnapshot.d.ts +2 -1
- package/virtualMachineSnapshot.js +2 -1
- package/virtualMachineSnapshot.js.map +1 -1
- package/vmfsDatastore.d.ts +54 -42
- package/vmfsDatastore.js +12 -15
- package/vmfsDatastore.js.map +1 -1
- package/vnic.d.ts +4 -3
- package/vnic.js +4 -3
- package/vnic.js.map +1 -1
|
@@ -2,19 +2,32 @@ import * as pulumi from "@pulumi/pulumi";
|
|
|
2
2
|
/**
|
|
3
3
|
* The `vsphere.ComputeClusterHostGroup` resource can be used to manage groups
|
|
4
4
|
* of hosts in a cluster, either created by the
|
|
5
|
-
* `vsphere.ComputeCluster` resource or looked up
|
|
6
|
-
* by the `vsphere.ComputeCluster` data source.
|
|
5
|
+
* [`vsphere.ComputeCluster`][tf-vsphere-cluster-resource] resource or looked up
|
|
6
|
+
* by the [`vsphere.ComputeCluster`][tf-vsphere-cluster-data-source] data source.
|
|
7
|
+
*
|
|
8
|
+
* [tf-vsphere-cluster-resource]: /docs/providers/vsphere/r/compute_cluster.html
|
|
9
|
+
* [tf-vsphere-cluster-data-source]: /docs/providers/vsphere/d/compute_cluster.html
|
|
7
10
|
*
|
|
8
11
|
* This resource mainly serves as an input to the
|
|
9
|
-
* `vsphere.ComputeClusterVmHostRule`
|
|
12
|
+
* [`vsphere.ComputeClusterVmHostRule`][tf-vsphere-cluster-vm-host-rule-resource]
|
|
10
13
|
* resource - see the documentation for that resource for further details on how
|
|
11
14
|
* to use host groups.
|
|
12
15
|
*
|
|
16
|
+
* [tf-vsphere-cluster-vm-host-rule-resource]: /docs/providers/vsphere/r/compute_cluster_vm_host_rule.html
|
|
17
|
+
*
|
|
13
18
|
* > **NOTE:** This resource requires vCenter and is not available on direct ESXi
|
|
14
19
|
* connections.
|
|
15
20
|
*
|
|
16
21
|
* ## Example Usage
|
|
17
22
|
*
|
|
23
|
+
* The example below is the exact same configuration as the
|
|
24
|
+
* [example][tf-vsphere-cluster-resource-example] in the
|
|
25
|
+
* [`vsphere.ComputeCluster`][tf-vsphere-cluster-resource] resource, but in
|
|
26
|
+
* addition, it creates a host group with the same hosts that get put into the
|
|
27
|
+
* cluster.
|
|
28
|
+
*
|
|
29
|
+
* [tf-vsphere-cluster-resource-example]: /docs/providers/vsphere/r/compute_cluster.html#example-usage
|
|
30
|
+
*
|
|
18
31
|
* ```typescript
|
|
19
32
|
* import * as pulumi from "@pulumi/pulumi";
|
|
20
33
|
* import * as vsphere from "@pulumi/vsphere";
|
|
@@ -34,15 +47,15 @@ import * as pulumi from "@pulumi/pulumi";
|
|
|
34
47
|
* datacenterId: _arg0_.id,
|
|
35
48
|
* })));
|
|
36
49
|
* const computeCluster = new vsphere.ComputeCluster("compute_cluster", {
|
|
37
|
-
* name: "compute-cluster-test",
|
|
38
|
-
* datacenterId:
|
|
50
|
+
* name: "pulumi-compute-cluster-test",
|
|
51
|
+
* datacenterId: datacenterGetDatacenter.then(datacenterGetDatacenter => datacenterGetDatacenter.id),
|
|
39
52
|
* hostSystemIds: [hostsGetHost.map(__item => __item.id)],
|
|
40
53
|
* drsEnabled: true,
|
|
41
54
|
* drsAutomationLevel: "fullyAutomated",
|
|
42
55
|
* haEnabled: true,
|
|
43
56
|
* });
|
|
44
57
|
* const clusterHostGroup = new vsphere.ComputeClusterHostGroup("cluster_host_group", {
|
|
45
|
-
* name: "test-cluster-host-group",
|
|
58
|
+
* name: "pulumi-test-cluster-host-group",
|
|
46
59
|
* computeClusterId: computeCluster.id,
|
|
47
60
|
* hostSystemIds: [hostsGetHost.map(__item => __item.id)],
|
|
48
61
|
* });
|
|
@@ -51,22 +64,17 @@ import * as pulumi from "@pulumi/pulumi";
|
|
|
51
64
|
* ## Import
|
|
52
65
|
*
|
|
53
66
|
* An existing group can be imported into this resource by
|
|
54
|
-
*
|
|
55
67
|
* supplying both the path to the cluster, and the name of the host group. If the
|
|
56
|
-
*
|
|
57
68
|
* name or cluster is not found, or if the group is of a different type, an error
|
|
58
|
-
*
|
|
59
69
|
* will be returned. An example is below:
|
|
60
70
|
*
|
|
61
71
|
* [docs-import]: https://developer.hashicorp.com/terraform/cli/import
|
|
62
72
|
*
|
|
63
73
|
* ```sh
|
|
64
|
-
*
|
|
65
|
-
* ```
|
|
66
|
-
*
|
|
74
|
+
* terraform import vsphere_compute_cluster_host_group.cluster_host_group \
|
|
67
75
|
* '{"compute_cluster_path": "/dc1/host/cluster1", \
|
|
68
|
-
*
|
|
69
76
|
* "name": "pulumi-test-cluster-host-group"}'
|
|
77
|
+
* ```
|
|
70
78
|
*/
|
|
71
79
|
export declare class ComputeClusterHostGroup extends pulumi.CustomResource {
|
|
72
80
|
/**
|
|
@@ -85,19 +93,23 @@ export declare class ComputeClusterHostGroup extends pulumi.CustomResource {
|
|
|
85
93
|
*/
|
|
86
94
|
static isInstance(obj: any): obj is ComputeClusterHostGroup;
|
|
87
95
|
/**
|
|
88
|
-
* The managed object reference
|
|
89
|
-
* ID of the cluster to put the group in. Forces a new
|
|
96
|
+
* The [managed object reference
|
|
97
|
+
* ID][docs-about-morefs] of the cluster to put the group in. Forces a new
|
|
90
98
|
* resource if changed.
|
|
99
|
+
*
|
|
100
|
+
* [docs-about-morefs]: /docs/providers/vsphere/index.html#use-of-managed-object-references-by-the-vsphere-provider
|
|
91
101
|
*/
|
|
92
102
|
readonly computeClusterId: pulumi.Output<string>;
|
|
93
103
|
/**
|
|
94
|
-
* The managed object IDs of
|
|
104
|
+
* The [managed object IDs][docs-about-morefs] of
|
|
95
105
|
* the hosts to put in the cluster.
|
|
96
106
|
*
|
|
97
107
|
* > **NOTE:** The namespace for cluster names on this resource (defined by the
|
|
98
108
|
* `name` argument) is shared with the
|
|
99
|
-
* `vsphere.ComputeClusterVmGroup`
|
|
109
|
+
* [`vsphere.ComputeClusterVmGroup`][tf-vsphere-cluster-vm-group-resource]
|
|
100
110
|
* resource. Make sure your names are unique across both resources.
|
|
111
|
+
*
|
|
112
|
+
* [tf-vsphere-cluster-vm-group-resource]: /docs/providers/vsphere/r/compute_cluster_vm_group.html
|
|
101
113
|
*/
|
|
102
114
|
readonly hostSystemIds: pulumi.Output<string[] | undefined>;
|
|
103
115
|
/**
|
|
@@ -119,19 +131,23 @@ export declare class ComputeClusterHostGroup extends pulumi.CustomResource {
|
|
|
119
131
|
*/
|
|
120
132
|
export interface ComputeClusterHostGroupState {
|
|
121
133
|
/**
|
|
122
|
-
* The managed object reference
|
|
123
|
-
* ID of the cluster to put the group in. Forces a new
|
|
134
|
+
* The [managed object reference
|
|
135
|
+
* ID][docs-about-morefs] of the cluster to put the group in. Forces a new
|
|
124
136
|
* resource if changed.
|
|
137
|
+
*
|
|
138
|
+
* [docs-about-morefs]: /docs/providers/vsphere/index.html#use-of-managed-object-references-by-the-vsphere-provider
|
|
125
139
|
*/
|
|
126
140
|
computeClusterId?: pulumi.Input<string>;
|
|
127
141
|
/**
|
|
128
|
-
* The managed object IDs of
|
|
142
|
+
* The [managed object IDs][docs-about-morefs] of
|
|
129
143
|
* the hosts to put in the cluster.
|
|
130
144
|
*
|
|
131
145
|
* > **NOTE:** The namespace for cluster names on this resource (defined by the
|
|
132
146
|
* `name` argument) is shared with the
|
|
133
|
-
* `vsphere.ComputeClusterVmGroup`
|
|
147
|
+
* [`vsphere.ComputeClusterVmGroup`][tf-vsphere-cluster-vm-group-resource]
|
|
134
148
|
* resource. Make sure your names are unique across both resources.
|
|
149
|
+
*
|
|
150
|
+
* [tf-vsphere-cluster-vm-group-resource]: /docs/providers/vsphere/r/compute_cluster_vm_group.html
|
|
135
151
|
*/
|
|
136
152
|
hostSystemIds?: pulumi.Input<pulumi.Input<string>[]>;
|
|
137
153
|
/**
|
|
@@ -145,19 +161,23 @@ export interface ComputeClusterHostGroupState {
|
|
|
145
161
|
*/
|
|
146
162
|
export interface ComputeClusterHostGroupArgs {
|
|
147
163
|
/**
|
|
148
|
-
* The managed object reference
|
|
149
|
-
* ID of the cluster to put the group in. Forces a new
|
|
164
|
+
* The [managed object reference
|
|
165
|
+
* ID][docs-about-morefs] of the cluster to put the group in. Forces a new
|
|
150
166
|
* resource if changed.
|
|
167
|
+
*
|
|
168
|
+
* [docs-about-morefs]: /docs/providers/vsphere/index.html#use-of-managed-object-references-by-the-vsphere-provider
|
|
151
169
|
*/
|
|
152
170
|
computeClusterId: pulumi.Input<string>;
|
|
153
171
|
/**
|
|
154
|
-
* The managed object IDs of
|
|
172
|
+
* The [managed object IDs][docs-about-morefs] of
|
|
155
173
|
* the hosts to put in the cluster.
|
|
156
174
|
*
|
|
157
175
|
* > **NOTE:** The namespace for cluster names on this resource (defined by the
|
|
158
176
|
* `name` argument) is shared with the
|
|
159
|
-
* `vsphere.ComputeClusterVmGroup`
|
|
177
|
+
* [`vsphere.ComputeClusterVmGroup`][tf-vsphere-cluster-vm-group-resource]
|
|
160
178
|
* resource. Make sure your names are unique across both resources.
|
|
179
|
+
*
|
|
180
|
+
* [tf-vsphere-cluster-vm-group-resource]: /docs/providers/vsphere/r/compute_cluster_vm_group.html
|
|
161
181
|
*/
|
|
162
182
|
hostSystemIds?: pulumi.Input<pulumi.Input<string>[]>;
|
|
163
183
|
/**
|
|
@@ -8,19 +8,32 @@ const utilities = require("./utilities");
|
|
|
8
8
|
/**
|
|
9
9
|
* The `vsphere.ComputeClusterHostGroup` resource can be used to manage groups
|
|
10
10
|
* of hosts in a cluster, either created by the
|
|
11
|
-
* `vsphere.ComputeCluster` resource or looked up
|
|
12
|
-
* by the `vsphere.ComputeCluster` data source.
|
|
11
|
+
* [`vsphere.ComputeCluster`][tf-vsphere-cluster-resource] resource or looked up
|
|
12
|
+
* by the [`vsphere.ComputeCluster`][tf-vsphere-cluster-data-source] data source.
|
|
13
|
+
*
|
|
14
|
+
* [tf-vsphere-cluster-resource]: /docs/providers/vsphere/r/compute_cluster.html
|
|
15
|
+
* [tf-vsphere-cluster-data-source]: /docs/providers/vsphere/d/compute_cluster.html
|
|
13
16
|
*
|
|
14
17
|
* This resource mainly serves as an input to the
|
|
15
|
-
* `vsphere.ComputeClusterVmHostRule`
|
|
18
|
+
* [`vsphere.ComputeClusterVmHostRule`][tf-vsphere-cluster-vm-host-rule-resource]
|
|
16
19
|
* resource - see the documentation for that resource for further details on how
|
|
17
20
|
* to use host groups.
|
|
18
21
|
*
|
|
22
|
+
* [tf-vsphere-cluster-vm-host-rule-resource]: /docs/providers/vsphere/r/compute_cluster_vm_host_rule.html
|
|
23
|
+
*
|
|
19
24
|
* > **NOTE:** This resource requires vCenter and is not available on direct ESXi
|
|
20
25
|
* connections.
|
|
21
26
|
*
|
|
22
27
|
* ## Example Usage
|
|
23
28
|
*
|
|
29
|
+
* The example below is the exact same configuration as the
|
|
30
|
+
* [example][tf-vsphere-cluster-resource-example] in the
|
|
31
|
+
* [`vsphere.ComputeCluster`][tf-vsphere-cluster-resource] resource, but in
|
|
32
|
+
* addition, it creates a host group with the same hosts that get put into the
|
|
33
|
+
* cluster.
|
|
34
|
+
*
|
|
35
|
+
* [tf-vsphere-cluster-resource-example]: /docs/providers/vsphere/r/compute_cluster.html#example-usage
|
|
36
|
+
*
|
|
24
37
|
* ```typescript
|
|
25
38
|
* import * as pulumi from "@pulumi/pulumi";
|
|
26
39
|
* import * as vsphere from "@pulumi/vsphere";
|
|
@@ -40,15 +53,15 @@ const utilities = require("./utilities");
|
|
|
40
53
|
* datacenterId: _arg0_.id,
|
|
41
54
|
* })));
|
|
42
55
|
* const computeCluster = new vsphere.ComputeCluster("compute_cluster", {
|
|
43
|
-
* name: "compute-cluster-test",
|
|
44
|
-
* datacenterId:
|
|
56
|
+
* name: "pulumi-compute-cluster-test",
|
|
57
|
+
* datacenterId: datacenterGetDatacenter.then(datacenterGetDatacenter => datacenterGetDatacenter.id),
|
|
45
58
|
* hostSystemIds: [hostsGetHost.map(__item => __item.id)],
|
|
46
59
|
* drsEnabled: true,
|
|
47
60
|
* drsAutomationLevel: "fullyAutomated",
|
|
48
61
|
* haEnabled: true,
|
|
49
62
|
* });
|
|
50
63
|
* const clusterHostGroup = new vsphere.ComputeClusterHostGroup("cluster_host_group", {
|
|
51
|
-
* name: "test-cluster-host-group",
|
|
64
|
+
* name: "pulumi-test-cluster-host-group",
|
|
52
65
|
* computeClusterId: computeCluster.id,
|
|
53
66
|
* hostSystemIds: [hostsGetHost.map(__item => __item.id)],
|
|
54
67
|
* });
|
|
@@ -57,22 +70,17 @@ const utilities = require("./utilities");
|
|
|
57
70
|
* ## Import
|
|
58
71
|
*
|
|
59
72
|
* An existing group can be imported into this resource by
|
|
60
|
-
*
|
|
61
73
|
* supplying both the path to the cluster, and the name of the host group. If the
|
|
62
|
-
*
|
|
63
74
|
* name or cluster is not found, or if the group is of a different type, an error
|
|
64
|
-
*
|
|
65
75
|
* will be returned. An example is below:
|
|
66
76
|
*
|
|
67
77
|
* [docs-import]: https://developer.hashicorp.com/terraform/cli/import
|
|
68
78
|
*
|
|
69
79
|
* ```sh
|
|
70
|
-
*
|
|
71
|
-
* ```
|
|
72
|
-
*
|
|
80
|
+
* terraform import vsphere_compute_cluster_host_group.cluster_host_group \
|
|
73
81
|
* '{"compute_cluster_path": "/dc1/host/cluster1", \
|
|
74
|
-
*
|
|
75
82
|
* "name": "pulumi-test-cluster-host-group"}'
|
|
83
|
+
* ```
|
|
76
84
|
*/
|
|
77
85
|
class ComputeClusterHostGroup extends pulumi.CustomResource {
|
|
78
86
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"computeClusterHostGroup.js","sourceRoot":"","sources":["../computeClusterHostGroup.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;;AAEjF,yCAAyC;AACzC,yCAAyC;AAEzC
|
|
1
|
+
{"version":3,"file":"computeClusterHostGroup.js","sourceRoot":"","sources":["../computeClusterHostGroup.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;;AAEjF,yCAAyC;AACzC,yCAAyC;AAEzC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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G,IAAI,EAAE,IAAI,CAAC;SACvC;QACD,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,CAAC,CAAC;QACnE,KAAK,CAAC,uBAAuB,CAAC,YAAY,EAAE,IAAI,EAAE,cAAc,EAAE,IAAI,CAAC,CAAC;IAC5E,CAAC;;AAjFL,0DAkFC;AApEG,gBAAgB;AACO,oCAAY,GAAG,+DAA+D,CAAC"}
|
|
@@ -2,8 +2,11 @@ import * as pulumi from "@pulumi/pulumi";
|
|
|
2
2
|
/**
|
|
3
3
|
* The `vsphere.ComputeClusterVmAffinityRule` resource can be used to
|
|
4
4
|
* manage virtual machine affinity rules in a cluster, either created by the
|
|
5
|
-
* `vsphere.ComputeCluster` resource or looked up
|
|
6
|
-
* by the `vsphere.ComputeCluster` data source.
|
|
5
|
+
* [`vsphere.ComputeCluster`][tf-vsphere-cluster-resource] resource or looked up
|
|
6
|
+
* by the [`vsphere.ComputeCluster`][tf-vsphere-cluster-data-source] data source.
|
|
7
|
+
*
|
|
8
|
+
* [tf-vsphere-cluster-resource]: /docs/providers/vsphere/r/compute_cluster.html
|
|
9
|
+
* [tf-vsphere-cluster-data-source]: /docs/providers/vsphere/d/compute_cluster.html
|
|
7
10
|
*
|
|
8
11
|
* This rule can be used to tell a set of virtual machines to run together on the
|
|
9
12
|
* same host within a cluster. When configured, DRS will make a best effort to
|
|
@@ -14,21 +17,25 @@ import * as pulumi from "@pulumi/pulumi";
|
|
|
14
17
|
* > An affinity rule can only be used to place virtual machines on the same
|
|
15
18
|
* _non-specific_ hosts. It cannot be used to pin virtual machines to a host.
|
|
16
19
|
* To enable this capability, use the
|
|
17
|
-
* `vsphere.ComputeClusterVmHostRule`
|
|
20
|
+
* [`vsphere.ComputeClusterVmHostRule`][tf-vsphere-cluster-vm-host-rule-resource]
|
|
18
21
|
* resource.
|
|
19
22
|
*
|
|
20
|
-
*
|
|
23
|
+
* [tf-vsphere-cluster-vm-host-rule-resource]: /docs/providers/vsphere/r/compute_cluster_vm_host_rule.html
|
|
24
|
+
*
|
|
25
|
+
* > **NOTE:** This resource requires vCenter and is not available on
|
|
21
26
|
* direct ESXi host connections.
|
|
22
27
|
*
|
|
23
28
|
* ## Example Usage
|
|
24
29
|
*
|
|
25
30
|
* The following example creates two virtual machines in a cluster using the
|
|
26
|
-
* `vsphere.VirtualMachine` resource, creating the
|
|
31
|
+
* [`vsphere.VirtualMachine`][tf-vsphere-vm-resource] resource, creating the
|
|
27
32
|
* virtual machines in the cluster looked up by the
|
|
28
|
-
* `vsphere.ComputeCluster` data source. It
|
|
33
|
+
* [`vsphere.ComputeCluster`][tf-vsphere-cluster-data-source] data source. It
|
|
29
34
|
* then creates an affinity rule for these two virtual machines, ensuring they
|
|
30
35
|
* will run on the same host whenever possible.
|
|
31
36
|
*
|
|
37
|
+
* [tf-vsphere-vm-resource]: /docs/providers/vsphere/r/virtual_machine.html
|
|
38
|
+
*
|
|
32
39
|
* ```typescript
|
|
33
40
|
* import * as pulumi from "@pulumi/pulumi";
|
|
34
41
|
* import * as vsphere from "@pulumi/vsphere";
|
|
@@ -75,7 +82,9 @@ import * as pulumi from "@pulumi/pulumi";
|
|
|
75
82
|
*
|
|
76
83
|
* The following example creates an affinity rule for a set of virtual machines
|
|
77
84
|
* in the cluster by looking up the virtual machine UUIDs from the
|
|
78
|
-
* `vsphere.VirtualMachine` data source.
|
|
85
|
+
* [`vsphere.VirtualMachine`][tf-vsphere-vm-data-source] data source.
|
|
86
|
+
*
|
|
87
|
+
* [tf-vsphere-vm-data-source]: /docs/providers/vsphere/d/virtual_machine.html
|
|
79
88
|
*
|
|
80
89
|
* ```typescript
|
|
81
90
|
* import * as pulumi from "@pulumi/pulumi";
|
|
@@ -107,20 +116,17 @@ import * as pulumi from "@pulumi/pulumi";
|
|
|
107
116
|
* ## Import
|
|
108
117
|
*
|
|
109
118
|
* An existing rule can be imported into this resource by supplying
|
|
110
|
-
*
|
|
111
119
|
* both the path to the cluster, and the name the rule. If the name or cluster is
|
|
112
|
-
*
|
|
113
120
|
* not found, or if the rule is of a different type, an error will be returned. An
|
|
114
|
-
*
|
|
115
121
|
* example is below:
|
|
116
122
|
*
|
|
117
|
-
*
|
|
118
|
-
* $ pulumi import vsphere:index/computeClusterVmAffinityRule:ComputeClusterVmAffinityRule vm_affinity_rule \
|
|
119
|
-
* ```
|
|
123
|
+
* [docs-import]: https://developer.hashicorp.com/terraform/cli/import
|
|
120
124
|
*
|
|
125
|
+
* ```sh
|
|
126
|
+
* terraform import vsphere_compute_cluster_vm_affinity_rule.vm_affinity_rule \
|
|
121
127
|
* '{"compute_cluster_path": "/dc-01/host/cluster-01", \
|
|
122
|
-
*
|
|
123
128
|
* "name": "vm-affinity-rule"}'
|
|
129
|
+
* ```
|
|
124
130
|
*/
|
|
125
131
|
export declare class ComputeClusterVmAffinityRule extends pulumi.CustomResource {
|
|
126
132
|
/**
|
|
@@ -139,9 +145,11 @@ export declare class ComputeClusterVmAffinityRule extends pulumi.CustomResource
|
|
|
139
145
|
*/
|
|
140
146
|
static isInstance(obj: any): obj is ComputeClusterVmAffinityRule;
|
|
141
147
|
/**
|
|
142
|
-
* The managed object reference
|
|
143
|
-
* ID of the cluster to put the group in. Forces a new
|
|
148
|
+
* The [managed object reference
|
|
149
|
+
* ID][docs-about-morefs] of the cluster to put the group in. Forces a new
|
|
144
150
|
* resource if changed.
|
|
151
|
+
*
|
|
152
|
+
* [docs-about-morefs]: /docs/providers/vsphere/index.html#use-of-managed-object-references-by-the-vsphere-provider
|
|
145
153
|
*/
|
|
146
154
|
readonly computeClusterId: pulumi.Output<string>;
|
|
147
155
|
/**
|
|
@@ -180,9 +188,11 @@ export declare class ComputeClusterVmAffinityRule extends pulumi.CustomResource
|
|
|
180
188
|
*/
|
|
181
189
|
export interface ComputeClusterVmAffinityRuleState {
|
|
182
190
|
/**
|
|
183
|
-
* The managed object reference
|
|
184
|
-
* ID of the cluster to put the group in. Forces a new
|
|
191
|
+
* The [managed object reference
|
|
192
|
+
* ID][docs-about-morefs] of the cluster to put the group in. Forces a new
|
|
185
193
|
* resource if changed.
|
|
194
|
+
*
|
|
195
|
+
* [docs-about-morefs]: /docs/providers/vsphere/index.html#use-of-managed-object-references-by-the-vsphere-provider
|
|
186
196
|
*/
|
|
187
197
|
computeClusterId?: pulumi.Input<string>;
|
|
188
198
|
/**
|
|
@@ -213,9 +223,11 @@ export interface ComputeClusterVmAffinityRuleState {
|
|
|
213
223
|
*/
|
|
214
224
|
export interface ComputeClusterVmAffinityRuleArgs {
|
|
215
225
|
/**
|
|
216
|
-
* The managed object reference
|
|
217
|
-
* ID of the cluster to put the group in. Forces a new
|
|
226
|
+
* The [managed object reference
|
|
227
|
+
* ID][docs-about-morefs] of the cluster to put the group in. Forces a new
|
|
218
228
|
* resource if changed.
|
|
229
|
+
*
|
|
230
|
+
* [docs-about-morefs]: /docs/providers/vsphere/index.html#use-of-managed-object-references-by-the-vsphere-provider
|
|
219
231
|
*/
|
|
220
232
|
computeClusterId: pulumi.Input<string>;
|
|
221
233
|
/**
|
|
@@ -8,8 +8,11 @@ const utilities = require("./utilities");
|
|
|
8
8
|
/**
|
|
9
9
|
* The `vsphere.ComputeClusterVmAffinityRule` resource can be used to
|
|
10
10
|
* manage virtual machine affinity rules in a cluster, either created by the
|
|
11
|
-
* `vsphere.ComputeCluster` resource or looked up
|
|
12
|
-
* by the `vsphere.ComputeCluster` data source.
|
|
11
|
+
* [`vsphere.ComputeCluster`][tf-vsphere-cluster-resource] resource or looked up
|
|
12
|
+
* by the [`vsphere.ComputeCluster`][tf-vsphere-cluster-data-source] data source.
|
|
13
|
+
*
|
|
14
|
+
* [tf-vsphere-cluster-resource]: /docs/providers/vsphere/r/compute_cluster.html
|
|
15
|
+
* [tf-vsphere-cluster-data-source]: /docs/providers/vsphere/d/compute_cluster.html
|
|
13
16
|
*
|
|
14
17
|
* This rule can be used to tell a set of virtual machines to run together on the
|
|
15
18
|
* same host within a cluster. When configured, DRS will make a best effort to
|
|
@@ -20,21 +23,25 @@ const utilities = require("./utilities");
|
|
|
20
23
|
* > An affinity rule can only be used to place virtual machines on the same
|
|
21
24
|
* _non-specific_ hosts. It cannot be used to pin virtual machines to a host.
|
|
22
25
|
* To enable this capability, use the
|
|
23
|
-
* `vsphere.ComputeClusterVmHostRule`
|
|
26
|
+
* [`vsphere.ComputeClusterVmHostRule`][tf-vsphere-cluster-vm-host-rule-resource]
|
|
24
27
|
* resource.
|
|
25
28
|
*
|
|
26
|
-
*
|
|
29
|
+
* [tf-vsphere-cluster-vm-host-rule-resource]: /docs/providers/vsphere/r/compute_cluster_vm_host_rule.html
|
|
30
|
+
*
|
|
31
|
+
* > **NOTE:** This resource requires vCenter and is not available on
|
|
27
32
|
* direct ESXi host connections.
|
|
28
33
|
*
|
|
29
34
|
* ## Example Usage
|
|
30
35
|
*
|
|
31
36
|
* The following example creates two virtual machines in a cluster using the
|
|
32
|
-
* `vsphere.VirtualMachine` resource, creating the
|
|
37
|
+
* [`vsphere.VirtualMachine`][tf-vsphere-vm-resource] resource, creating the
|
|
33
38
|
* virtual machines in the cluster looked up by the
|
|
34
|
-
* `vsphere.ComputeCluster` data source. It
|
|
39
|
+
* [`vsphere.ComputeCluster`][tf-vsphere-cluster-data-source] data source. It
|
|
35
40
|
* then creates an affinity rule for these two virtual machines, ensuring they
|
|
36
41
|
* will run on the same host whenever possible.
|
|
37
42
|
*
|
|
43
|
+
* [tf-vsphere-vm-resource]: /docs/providers/vsphere/r/virtual_machine.html
|
|
44
|
+
*
|
|
38
45
|
* ```typescript
|
|
39
46
|
* import * as pulumi from "@pulumi/pulumi";
|
|
40
47
|
* import * as vsphere from "@pulumi/vsphere";
|
|
@@ -81,7 +88,9 @@ const utilities = require("./utilities");
|
|
|
81
88
|
*
|
|
82
89
|
* The following example creates an affinity rule for a set of virtual machines
|
|
83
90
|
* in the cluster by looking up the virtual machine UUIDs from the
|
|
84
|
-
* `vsphere.VirtualMachine` data source.
|
|
91
|
+
* [`vsphere.VirtualMachine`][tf-vsphere-vm-data-source] data source.
|
|
92
|
+
*
|
|
93
|
+
* [tf-vsphere-vm-data-source]: /docs/providers/vsphere/d/virtual_machine.html
|
|
85
94
|
*
|
|
86
95
|
* ```typescript
|
|
87
96
|
* import * as pulumi from "@pulumi/pulumi";
|
|
@@ -113,20 +122,17 @@ const utilities = require("./utilities");
|
|
|
113
122
|
* ## Import
|
|
114
123
|
*
|
|
115
124
|
* An existing rule can be imported into this resource by supplying
|
|
116
|
-
*
|
|
117
125
|
* both the path to the cluster, and the name the rule. If the name or cluster is
|
|
118
|
-
*
|
|
119
126
|
* not found, or if the rule is of a different type, an error will be returned. An
|
|
120
|
-
*
|
|
121
127
|
* example is below:
|
|
122
128
|
*
|
|
123
|
-
*
|
|
124
|
-
* $ pulumi import vsphere:index/computeClusterVmAffinityRule:ComputeClusterVmAffinityRule vm_affinity_rule \
|
|
125
|
-
* ```
|
|
129
|
+
* [docs-import]: https://developer.hashicorp.com/terraform/cli/import
|
|
126
130
|
*
|
|
131
|
+
* ```sh
|
|
132
|
+
* terraform import vsphere_compute_cluster_vm_affinity_rule.vm_affinity_rule \
|
|
127
133
|
* '{"compute_cluster_path": "/dc-01/host/cluster-01", \
|
|
128
|
-
*
|
|
129
134
|
* "name": "vm-affinity-rule"}'
|
|
135
|
+
* ```
|
|
130
136
|
*/
|
|
131
137
|
class ComputeClusterVmAffinityRule extends pulumi.CustomResource {
|
|
132
138
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"computeClusterVmAffinityRule.js","sourceRoot":"","sources":["../computeClusterVmAffinityRule.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;;AAEjF,yCAAyC;AACzC,yCAAyC;AAEzC
|
|
1
|
+
{"version":3,"file":"computeClusterVmAffinityRule.js","sourceRoot":"","sources":["../computeClusterVmAffinityRule.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;;AAEjF,yCAAy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AAC;YACzE,IAAI,IAAI,EAAE,gBAAgB,KAAK,SAAS,IAAI,CAAC,IAAI,CAAC,GAAG,EAAE;gBACnD,MAAM,IAAI,KAAK,CAAC,8CAA8C,CAAC,CAAC;aACnE;YACD,IAAI,IAAI,EAAE,iBAAiB,KAAK,SAAS,IAAI,CAAC,IAAI,CAAC,GAAG,EAAE;gBACpD,MAAM,IAAI,KAAK,CAAC,+CAA+C,CAAC,CAAC;aACpE;YACD,cAAc,CAAC,kBAAkB,CAAC,GAAG,IAAI,EAAE,gBAAgB,CAAC;YAC5D,cAAc,CAAC,SAAS,CAAC,GAAG,IAAI,EAAE,OAAO,CAAC;YAC1C,cAAc,CAAC,WAAW,CAAC,GAAG,IAAI,EAAE,SAAS,CAAC;YAC9C,cAAc,CAAC,MAAM,CAAC,GAAG,IAAI,EAAE,IAAI,CAAC;YACpC,cAAc,CAAC,mBAAmB,CAAC,GAAG,IAAI,EAAE,iBAAiB,CAAC;SACjE;QACD,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,CAAC,CAAC;QACnE,KAAK,CAAC,4BAA4B,CAAC,YAAY,EAAE,IAAI,EAAE,cAAc,EAAE,IAAI,CAAC,CAAC;IACjF,CAAC;;AA7FL,oEA8FC;AAhFG,gBAAgB;AACO,yCAAY,GAAG,yEAAyE,CAAC"}
|
|
@@ -1,24 +1,45 @@
|
|
|
1
1
|
import * as pulumi from "@pulumi/pulumi";
|
|
2
2
|
/**
|
|
3
|
+
* The `vsphere.ComputeClusterVmAntiAffinityRule` resource can be used to
|
|
4
|
+
* manage virtual machine anti-affinity rules in a cluster, either created by the
|
|
5
|
+
* [`vsphere.ComputeCluster`][tf-vsphere-cluster-resource] resource or looked up
|
|
6
|
+
* by the [`vsphere.ComputeCluster`][tf-vsphere-cluster-data-source] data source.
|
|
7
|
+
*
|
|
8
|
+
* [tf-vsphere-cluster-resource]: /docs/providers/vsphere/r/compute_cluster.html
|
|
9
|
+
* [tf-vsphere-cluster-data-source]: /docs/providers/vsphere/d/compute_cluster.html
|
|
10
|
+
*
|
|
11
|
+
* An anti-affinity rule places a group of virtual machines across different
|
|
12
|
+
* hosts within a cluster, and is useful for preventing single points of failure in
|
|
13
|
+
* application cluster scenarios. When configured, vSphere DRS will make a best effort
|
|
14
|
+
* to ensure that the virtual machines run on different hosts, or prevent any
|
|
15
|
+
* operation that would keep that from happening, depending on the value of the
|
|
16
|
+
* `mandatory` flag.
|
|
17
|
+
*
|
|
18
|
+
* > An anti-affinity rule can only be used to place virtual machines on separate
|
|
19
|
+
* _non-specific_ hosts. Specific hosts cannot be specified with this rule.
|
|
20
|
+
* To enable this capability, use VM-Host Groups, see the
|
|
21
|
+
* [`vsphere.ComputeClusterVmHostRule`][tf-vsphere-cluster-vm-host-rule-resource]
|
|
22
|
+
* resource.
|
|
23
|
+
*
|
|
24
|
+
* [tf-vsphere-cluster-vm-host-rule-resource]: /docs/providers/vsphere/r/compute_cluster_vm_host_rule.html
|
|
25
|
+
*
|
|
26
|
+
* > **NOTE:** This resource requires vCenter and is not available on
|
|
27
|
+
* direct ESXi host connections.
|
|
28
|
+
*
|
|
3
29
|
* ## Import
|
|
4
30
|
*
|
|
5
31
|
* An existing rule can be imported into this resource by supplying
|
|
6
|
-
*
|
|
7
32
|
* both the path to the cluster, and the name the rule. If the name or cluster is
|
|
8
|
-
*
|
|
9
33
|
* not found, or if the rule is of a different type, an error will be returned. An
|
|
10
|
-
*
|
|
11
34
|
* example is below:
|
|
12
35
|
*
|
|
13
36
|
* [docs-import]: https://developer.hashicorp.com/terraform/cli/import
|
|
14
37
|
*
|
|
15
38
|
* ```sh
|
|
16
|
-
*
|
|
17
|
-
* ```
|
|
18
|
-
*
|
|
39
|
+
* terraform import vsphere_compute_cluster_vm_anti_affinity_rule.vm_anti_affinity_rule \
|
|
19
40
|
* '{"compute_cluster_path": "/dc-01/host/cluster-01", \
|
|
20
|
-
*
|
|
21
41
|
* "name": "vm-anti-affinity-rule"}'
|
|
42
|
+
* ```
|
|
22
43
|
*/
|
|
23
44
|
export declare class ComputeClusterVmAntiAffinityRule extends pulumi.CustomResource {
|
|
24
45
|
/**
|
|
@@ -37,9 +58,11 @@ export declare class ComputeClusterVmAntiAffinityRule extends pulumi.CustomResou
|
|
|
37
58
|
*/
|
|
38
59
|
static isInstance(obj: any): obj is ComputeClusterVmAntiAffinityRule;
|
|
39
60
|
/**
|
|
40
|
-
* The managed object reference
|
|
41
|
-
* ID of the cluster to put the group in. Forces a new
|
|
61
|
+
* The [managed object reference
|
|
62
|
+
* ID][docs-about-morefs] of the cluster to put the group in. Forces a new
|
|
42
63
|
* resource if changed.
|
|
64
|
+
*
|
|
65
|
+
* [docs-about-morefs]: /docs/providers/vsphere/index.html#use-of-managed-object-references-by-the-vsphere-provider
|
|
43
66
|
*/
|
|
44
67
|
readonly computeClusterId: pulumi.Output<string>;
|
|
45
68
|
/**
|
|
@@ -78,9 +101,11 @@ export declare class ComputeClusterVmAntiAffinityRule extends pulumi.CustomResou
|
|
|
78
101
|
*/
|
|
79
102
|
export interface ComputeClusterVmAntiAffinityRuleState {
|
|
80
103
|
/**
|
|
81
|
-
* The managed object reference
|
|
82
|
-
* ID of the cluster to put the group in. Forces a new
|
|
104
|
+
* The [managed object reference
|
|
105
|
+
* ID][docs-about-morefs] of the cluster to put the group in. Forces a new
|
|
83
106
|
* resource if changed.
|
|
107
|
+
*
|
|
108
|
+
* [docs-about-morefs]: /docs/providers/vsphere/index.html#use-of-managed-object-references-by-the-vsphere-provider
|
|
84
109
|
*/
|
|
85
110
|
computeClusterId?: pulumi.Input<string>;
|
|
86
111
|
/**
|
|
@@ -111,9 +136,11 @@ export interface ComputeClusterVmAntiAffinityRuleState {
|
|
|
111
136
|
*/
|
|
112
137
|
export interface ComputeClusterVmAntiAffinityRuleArgs {
|
|
113
138
|
/**
|
|
114
|
-
* The managed object reference
|
|
115
|
-
* ID of the cluster to put the group in. Forces a new
|
|
139
|
+
* The [managed object reference
|
|
140
|
+
* ID][docs-about-morefs] of the cluster to put the group in. Forces a new
|
|
116
141
|
* resource if changed.
|
|
142
|
+
*
|
|
143
|
+
* [docs-about-morefs]: /docs/providers/vsphere/index.html#use-of-managed-object-references-by-the-vsphere-provider
|
|
117
144
|
*/
|
|
118
145
|
computeClusterId: pulumi.Input<string>;
|
|
119
146
|
/**
|
|
@@ -6,25 +6,46 @@ exports.ComputeClusterVmAntiAffinityRule = void 0;
|
|
|
6
6
|
const pulumi = require("@pulumi/pulumi");
|
|
7
7
|
const utilities = require("./utilities");
|
|
8
8
|
/**
|
|
9
|
+
* The `vsphere.ComputeClusterVmAntiAffinityRule` resource can be used to
|
|
10
|
+
* manage virtual machine anti-affinity rules in a cluster, either created by the
|
|
11
|
+
* [`vsphere.ComputeCluster`][tf-vsphere-cluster-resource] resource or looked up
|
|
12
|
+
* by the [`vsphere.ComputeCluster`][tf-vsphere-cluster-data-source] data source.
|
|
13
|
+
*
|
|
14
|
+
* [tf-vsphere-cluster-resource]: /docs/providers/vsphere/r/compute_cluster.html
|
|
15
|
+
* [tf-vsphere-cluster-data-source]: /docs/providers/vsphere/d/compute_cluster.html
|
|
16
|
+
*
|
|
17
|
+
* An anti-affinity rule places a group of virtual machines across different
|
|
18
|
+
* hosts within a cluster, and is useful for preventing single points of failure in
|
|
19
|
+
* application cluster scenarios. When configured, vSphere DRS will make a best effort
|
|
20
|
+
* to ensure that the virtual machines run on different hosts, or prevent any
|
|
21
|
+
* operation that would keep that from happening, depending on the value of the
|
|
22
|
+
* `mandatory` flag.
|
|
23
|
+
*
|
|
24
|
+
* > An anti-affinity rule can only be used to place virtual machines on separate
|
|
25
|
+
* _non-specific_ hosts. Specific hosts cannot be specified with this rule.
|
|
26
|
+
* To enable this capability, use VM-Host Groups, see the
|
|
27
|
+
* [`vsphere.ComputeClusterVmHostRule`][tf-vsphere-cluster-vm-host-rule-resource]
|
|
28
|
+
* resource.
|
|
29
|
+
*
|
|
30
|
+
* [tf-vsphere-cluster-vm-host-rule-resource]: /docs/providers/vsphere/r/compute_cluster_vm_host_rule.html
|
|
31
|
+
*
|
|
32
|
+
* > **NOTE:** This resource requires vCenter and is not available on
|
|
33
|
+
* direct ESXi host connections.
|
|
34
|
+
*
|
|
9
35
|
* ## Import
|
|
10
36
|
*
|
|
11
37
|
* An existing rule can be imported into this resource by supplying
|
|
12
|
-
*
|
|
13
38
|
* both the path to the cluster, and the name the rule. If the name or cluster is
|
|
14
|
-
*
|
|
15
39
|
* not found, or if the rule is of a different type, an error will be returned. An
|
|
16
|
-
*
|
|
17
40
|
* example is below:
|
|
18
41
|
*
|
|
19
42
|
* [docs-import]: https://developer.hashicorp.com/terraform/cli/import
|
|
20
43
|
*
|
|
21
44
|
* ```sh
|
|
22
|
-
*
|
|
23
|
-
* ```
|
|
24
|
-
*
|
|
45
|
+
* terraform import vsphere_compute_cluster_vm_anti_affinity_rule.vm_anti_affinity_rule \
|
|
25
46
|
* '{"compute_cluster_path": "/dc-01/host/cluster-01", \
|
|
26
|
-
*
|
|
27
47
|
* "name": "vm-anti-affinity-rule"}'
|
|
48
|
+
* ```
|
|
28
49
|
*/
|
|
29
50
|
class ComputeClusterVmAntiAffinityRule extends pulumi.CustomResource {
|
|
30
51
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"computeClusterVmAntiAffinityRule.js","sourceRoot":"","sources":["../computeClusterVmAntiAffinityRule.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;;AAEjF,yCAAyC;AACzC,yCAAyC;AAEzC
|
|
1
|
+
{"version":3,"file":"computeClusterVmAntiAffinityRule.js","sourceRoot":"","sources":["../computeClusterVmAntiAffinityRule.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;;AAEjF,yCAAyC;AACzC,yCAAyC;AAEzC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAyCG;AACH,MAAa,gCAAiC,SAAQ,MAAM,CAA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