terraform: fix merge issues with master

This commit is contained in:
Mitchell Hashimoto 2016-10-19 13:41:30 -07:00
parent 5cd6898109
commit e59efa024b
No known key found for this signature in database
GPG Key ID: 744E147AA52F5B0A
1 changed files with 6 additions and 26 deletions

View File

@ -13,10 +13,6 @@ import (
"github.com/hashicorp/terraform/config/module" "github.com/hashicorp/terraform/config/module"
) )
// InputMode defines what sort of input will be asked for when Input
// is called on Context.
type InputMode byte
// Variables prefixed with X_ are experimental features. They can be enabled // Variables prefixed with X_ are experimental features. They can be enabled
// by setting them to true. This should be done before any API is called. // by setting them to true. This should be done before any API is called.
// These should be expected to be removed at some point in the future; each // These should be expected to be removed at some point in the future; each
@ -27,6 +23,10 @@ var (
X_newApply = false X_newApply = false
) )
// InputMode defines what sort of input will be asked for when Input
// is called on Context.
type InputMode byte
const ( const (
// InputModeVar asks for all variables // InputModeVar asks for all variables
InputModeVar InputMode = 1 << iota InputModeVar InputMode = 1 << iota
@ -372,11 +372,9 @@ func (c *Context) Apply() (*State, error) {
graph, err = c.Graph(&ContextGraphOpts{Validate: true}) graph, err = c.Graph(&ContextGraphOpts{Validate: true})
} else { } else {
graph, err = (&ApplyGraphBuilder{ graph, err = (&ApplyGraphBuilder{
Module: c.module,
Diff: c.diff, Diff: c.diff,
State: c.state, Providers: c.components.ResourceProviders(),
Providers: c.providersList(), Provisioners: c.components.ResourceProvisioners(),
Provisioners: c.provisionersList(),
}).Build(RootModulePath) }).Build(RootModulePath)
} }
if err != nil { if err != nil {
@ -733,24 +731,6 @@ func (c *Context) walk(
return walker, realErr return walker, realErr
} }
func (c *Context) providersList() []string {
providers := make([]string, 0, len(c.providers))
for k, _ := range c.providers {
providers = append(providers, k)
}
return providers
}
func (c *Context) provisionersList() []string {
provisioners := make([]string, 0, len(c.provisioners))
for k, _ := range c.provisioners {
provisioners = append(provisioners, k)
}
return provisioners
}
// parseVariableAsHCL parses the value of a single variable as would have been specified // parseVariableAsHCL parses the value of a single variable as would have been specified
// on the command line via -var or in an environment variable named TF_VAR_x, where x is // on the command line via -var or in an environment variable named TF_VAR_x, where x is
// the name of the variable. In order to get around the restriction of HCL requiring a // the name of the variable. In order to get around the restriction of HCL requiring a