github.com/bengesoff/terraform@v0.3.1-0.20141018223233-b25a53629922/website/source/docs/commands/graph.html.markdown (about)

     1  ---
     2  layout: "docs"
     3  page_title: "Command: graph"
     4  sidebar_current: "docs-commands-graph"
     5  ---
     6  
     7  # Command: graph
     8  
     9  The `terraform graph` command is used to generate a visual
    10  representation of either a configuration or execution plan.
    11  The output is in the DOT format, which can be used by
    12  [GraphViz](http://www.graphviz.org) to generate charts.
    13  
    14  
    15  ## Usage
    16  
    17  Usage: `terraform output [options] [input]`
    18  
    19  By default, `output` scans the current directory for the configuration
    20  and generates the output for that configuration. However, a path to
    21  another configuration or an execution plan can be provided. Execution plans
    22  provide more details on creation, deletion or changes.
    23  
    24  ## Generating Images
    25  
    26  The output of `terraform graph` is in the DOT format, which can
    27  easily be converted to an image by making use of `dot` provided
    28  by GraphViz:
    29  
    30  ```
    31  $ terraform graph | dot -Tpng > graph.png
    32  ```
    33  
    34  Alternatively, the web-based [GraphViz Workspace](http://graphviz-dev.appspot.com)
    35  can be used to quickly render DOT file inputs as well.
    36  
    37  Here is an example graph output:
    38  ![Graph Example](/images/graph-example.png)
    39