From f857363aac67534640e077c7c739804cea574b32 Mon Sep 17 00:00:00 2001 From: Mitchell Hashimoto Date: Mon, 9 Mar 2015 11:06:25 -0700 Subject: [PATCH] website: document push --- .../source/docs/commands/push.html.markdown | 53 +++++++++++++++++ .../source/docs/configuration/atlas.html.md | 58 +++++++++++++++++++ website/source/layouts/docs.erb | 8 +++ 3 files changed, 119 insertions(+) create mode 100644 website/source/docs/commands/push.html.markdown create mode 100644 website/source/docs/configuration/atlas.html.md diff --git a/website/source/docs/commands/push.html.markdown b/website/source/docs/commands/push.html.markdown new file mode 100644 index 000000000..5235b5754 --- /dev/null +++ b/website/source/docs/commands/push.html.markdown @@ -0,0 +1,53 @@ +--- +layout: "docs" +page_title: "Command: push" +sidebar_current: "docs-commands-push" +description: |- + The `terraform push` command is used to upload the Terraform configuration to HashiCorp's Atlas service for automatically managing your infrastructure in the cloud. +--- + +# Command: push + +The `terraform push` command uploads your Terraform configuration to +be managed by HashiCorp's [Atlas](https://atlas.hashicorp.com). +By uploading your configuration to Atlas, Atlas can automatically run +Terraform for you, will save all state transitions, will save plans, +and will keep a history of all Terraform runs. + +This makes it significantly easier to use Terraform as a team: team +members modify the Terraform configurations locally and continue to +use normal version control. When the Terraform configurations are ready +to be run, they are pushed to Atlas, and any member of your team can +run Terraform with the push of a button. + +Atlas can also be used to set ACLs on who can run Terraform, and a +future update of Atlas will allow parallel Terraform runs and automatically +perform infrastructure locking so only one run is modifying the same +infrastructure at a time. + +## Usage + +Usage: `terraform push [options] [path]` + +The `path` argument is the same as for the +[apply](/docs/commands/apply.html) command. + +The command-line flags are all optional. The list of available flags are: + +* `-module-upload=true` - If true (default), then the + [modules](/docs/modules/index.html) + being used are all locked at their current checkout and uploaded + completely to Atlas. This prevents Atlas from running `terraform get` + for you. + +* `-name=` - Name of the infrastructure configuration in Atlas. + The format of this is: "username/name" so that you can upload + configurations not just to your account but to other accounts and + organizations. This setting can also be set in the configuration + in the + [Atlas section](#). + +* `-no-color` - Disables output with coloring + +* `-token=` - Atlas API token to use to authorize the upload. + If blank, the `ATLAS_TOKEN` environmental variable will be used. diff --git a/website/source/docs/configuration/atlas.html.md b/website/source/docs/configuration/atlas.html.md new file mode 100644 index 000000000..e975c88ba --- /dev/null +++ b/website/source/docs/configuration/atlas.html.md @@ -0,0 +1,58 @@ +--- +layout: "docs" +page_title: "Configuring Atlas" +sidebar_current: "docs-config-atlas" +description: |- + Atlas is the ideal way to use Terraform in a team environment. Atlas will run Terraform for you, safely handle parallelization across different team members, save run history along with plans, and more. +--- + +# Atlas Configuration + +Terraform can be configured to be able to upload to HashiCorp's +[Atlas](https://atlas.hashicorp.com). This configuration doesn't change +the behavior of Terraform itself, it only configures your Terraform +configuration to support being uploaded to Atlas via the +[push command](/docs/commands/push.html). + +For more information on the benefits of uploading your Terraform +configuration to Atlas, please see the +[push command documentation](/docs/commands/push.html). + +This page assumes you're familiar with the +[configuration syntax](/docs/configuration/syntax.html) +already. + +## Example + +Atlas configuration looks like the following: + +``` +atlas { + name = "mitchellh/production-example" +} +``` + +## Description + +The `atlas` block configures the settings when Terraform is +[pushed](/docs/commands/push.html) to Atlas. Only one `atlas` block +is allowed. + +Within the block (the `{ }`) is configuration for Atlas uploading. +No keys are required, but the key typically set is `name`. + +**No value within the `atlas` block can use interpolations.** Due +to the nature of this configuration, interpolations are not possible. +If you want to parameterize these settings, use the Atlas block to +set defaults, then use the command-line flags of the +[push command](/docs/commands/push.html) to override. + +## Syntax + +The full syntax is: + +``` +atlas { + name = VALUE +} +``` diff --git a/website/source/layouts/docs.erb b/website/source/layouts/docs.erb index fa8bce84a..a0b31127a 100644 --- a/website/source/layouts/docs.erb +++ b/website/source/layouts/docs.erb @@ -45,6 +45,10 @@ Modules + > + Atlas + + @@ -79,6 +83,10 @@ plan + > + push + + > refresh