Skip to content

Commit

Permalink
r/datacenter: Update docs related to ESXi
Browse files Browse the repository at this point in the history
Couple of things:

* Clarified the nature of the "default" datacenter on ESXi and how the
name attribute has no meaning.
* Moved all of this detail to the warning text.
* Have decided (not 100% related to this resource) that vsphere_host
will _require_ the vsphere_datacenter data source's output, even if
using ESXi. The purpose of these data sources and moving to using MoRefs
as the source of truth is to reduce ambiguity, and as such we shouldn't
be introducing ambiguity in.
  • Loading branch information
vancluever committed Aug 30, 2017
1 parent 03ef7d2 commit d23cba6
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions website/docs/d/datacenter.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ description: |-
# vsphere\_datacenter

The `vsphere_datacenter` data source can be used to discover the ID of a
vSphere datacenter. It can also be used to fetch the "default datacenter" on
ESXi, however this can be done with [`vsphere_host`][data-source-vsphere-host]
as well.
vSphere datacenter. This can then be used with resources or data sources that
require a datacenter, such as the [`vsphere_host`][data-source-vsphere-host]
data source.

[data-source-vsphere-host]: /docs/providers/vsphere/d/host.html

Expand All @@ -30,7 +30,10 @@ The following arguments are supported:
* `name` - (String) The name of the datacenter. This can be a name or path. If
not provided, the default datacenter is used.

~> **NOTE:** `name` is ignored on ESXi, and is not required.
~> **NOTE:** When used against ESXi, this data source _always_ fetches the
server's "default" datacenter, which is a special datacenter unrelated to the
default datacenter that exists in vCenter. Hence, the `name` attribute is
completely ignored.

## Attribute Reference

Expand Down

0 comments on commit d23cba6

Please sign in to comment.