website: fix JSON typo (resources is array of objects)

This commit is contained in:
Nick Fagerlund 2019-02-20 17:56:00 -08:00
parent ff47cab8c7
commit c2979e7278
1 changed files with 38 additions and 36 deletions

View File

@ -45,47 +45,49 @@ The following example illustrates the structure of the common `<values-represent
// "root_module" describes the resources and child modules in the root module. // "root_module" describes the resources and child modules in the root module.
"root_module": { "root_module": {
"resources": [ "resources": [
// "address" is the absolute resource address, which callers must consider {
// opaque but may do full string comparisons with other address strings or // "address" is the absolute resource address, which callers must consider
// pass this verbatim to other Terraform commands that are documented to // opaque but may do full string comparisons with other address strings or
// accept absolute resource addresses. The module-local portions of this // pass this verbatim to other Terraform commands that are documented to
// address are extracted in other properties below. // accept absolute resource addresses. The module-local portions of this
"address": "aws_instance.example[1]", // address are extracted in other properties below.
"address": "aws_instance.example[1]",
// "mode" can be "managed", for resources, or "data", for data resources // "mode" can be "managed", for resources, or "data", for data resources
"mode": "managed", "mode": "managed",
"type": "aws_instance", "type": "aws_instance",
"name": "example", "name": "example",
// If the count or for_each meta-arguments are set for this resource, the // If the count or for_each meta-arguments are set for this resource, the
// additional key "index" is present to give the instance index key. This // additional key "index" is present to give the instance index key. This
// is omitted for the single instance of a resource that isn't using count // is omitted for the single instance of a resource that isn't using count
// or for_each. // or for_each.
"index": 1, "index": 1,
// "provider_name" is the name of the provider that is responsible for // "provider_name" is the name of the provider that is responsible for
// this resource. This is only the provider name, not a provider // this resource. This is only the provider name, not a provider
// configuration address, and so no module path nor alias will be // configuration address, and so no module path nor alias will be
// indicated here. This is included to allow the property "type" to be // indicated here. This is included to allow the property "type" to be
// interpreted unambiguously in the unusual situation where a provider // interpreted unambiguously in the unusual situation where a provider
// offers a resource type whose name does not start with its own name, // offers a resource type whose name does not start with its own name,
// such as the "googlebeta" provider offering "google_compute_instance". // such as the "googlebeta" provider offering "google_compute_instance".
"provider_name": "aws", "provider_name": "aws",
// "schema_version" indicates which version of the resource type schema // "schema_version" indicates which version of the resource type schema
// the "values" property conforms to. // the "values" property conforms to.
"schema_version": 2, "schema_version": 2,
// "values" is the JSON representation of the attribute values of the // "values" is the JSON representation of the attribute values of the
// resource, whose structure depends on the resource type schema. Any // resource, whose structure depends on the resource type schema. Any
// unknown values are omitted or set to null, making them // unknown values are omitted or set to null, making them
// indistinguishable from absent values; callers which need to distinguish // indistinguishable from absent values; callers which need to distinguish
// unknown from unset must use the plan-specific or config-specific // unknown from unset must use the plan-specific or config-specific
// structures described in later sections. // structures described in later sections.
"values": { "values": {
"id": "i-abc123", "id": "i-abc123",
"instance_type": "t2.micro", "instance_type": "t2.micro",
// etc, etc // etc, etc
}
} }
] ]