website: Initial docs for the new "providers" subcommand

This will be fleshed out later as part of more holistic documentation for
the new provider plugin separation, but this is some minimal documentation
for just this subcommand.
This commit is contained in:
Martin Atkins 2017-04-28 15:32:23 -07:00
parent 3af0ecdf01
commit d7d8ea9543
3 changed files with 41 additions and 0 deletions

View File

@ -41,6 +41,7 @@ Common commands:
init Initialize a new or existing Terraform configuration
output Read an output from a state file
plan Generate and show an execution plan
providers Prints a tree of the providers used in the configuration
push Upload this Terraform module to Terraform Enterprise to run
refresh Update local state file against real resources
show Inspect Terraform state or plan

View File

@ -0,0 +1,36 @@
---
layout: "docs"
page_title: "Command: providers"
sidebar_current: "docs-commands-providers"
description: |-
The "providers" sub-command prints information about the providers used
in the current configuration.
---
# Command: show
The `terraform providers` command prints information about the providers
used in the current configuration.
Provider dependencies are created in several different ways:
* Explicit use of a `provider` block in configuration, optionally including
a version constraint.
* Use of any resource belonging to a particular provider in a `resource` or
`data` block in configuration.
* Existance of any resource instance belonging to a particular provider in
the current _state_. For example, if a particular resource is removed
from configuration, it continues to create a dependency on its provider
until its instances have been destroyed.
This command gives an overview of all of the current dependencies, as an aid
to understanding why a particular provider is needed.
## Usage
Usage: `terraform show [config-path]`
Pass an explicit configuration path to override the default of using the
current working directory.

View File

@ -109,6 +109,10 @@
<a href="/docs/commands/plan.html">plan</a>
</li>
<li<%= sidebar_current("docs-commands-providers") %>>
<a href="/docs/commands/providers.html">providers</a>
</li>
<li<%= sidebar_current("docs-commands-push") %>>
<a href="/docs/commands/push.html">push</a>
</li>