provider/aws: OpsWorks updates (#12979)

* provider/aws: Opsworks updates to allow minimal configuration

* update
This commit is contained in:
Clint 2017-03-22 15:26:47 -05:00 committed by GitHub
parent 8b4dac8442
commit cde1afbfd3
1 changed files with 5 additions and 1 deletions

View File

@ -71,7 +71,7 @@ func resourceAwsOpsworksStack() *schema.Resource {
"configuration_manager_version": { "configuration_manager_version": {
Type: schema.TypeString, Type: schema.TypeString,
Optional: true, Optional: true,
Default: "11.4", Default: "11.10",
}, },
"manage_berkshelf": { "manage_berkshelf": {
@ -156,6 +156,7 @@ func resourceAwsOpsworksStack() *schema.Resource {
"default_subnet_id": { "default_subnet_id": {
Type: schema.TypeString, Type: schema.TypeString,
Optional: true, Optional: true,
Computed: true,
}, },
"hostname_theme": { "hostname_theme": {
@ -179,6 +180,7 @@ func resourceAwsOpsworksStack() *schema.Resource {
"vpc_id": { "vpc_id": {
Type: schema.TypeString, Type: schema.TypeString,
ForceNew: true, ForceNew: true,
Computed: true,
Optional: true, Optional: true,
}, },
}, },
@ -431,10 +433,12 @@ func resourceAwsOpsworksStackUpdate(d *schema.ResourceData, meta interface{}) er
if v, ok := d.GetOk("color"); ok { if v, ok := d.GetOk("color"); ok {
req.Attributes["Color"] = aws.String(v.(string)) req.Attributes["Color"] = aws.String(v.(string))
} }
req.ChefConfiguration = &opsworks.ChefConfiguration{ req.ChefConfiguration = &opsworks.ChefConfiguration{
BerkshelfVersion: aws.String(d.Get("berkshelf_version").(string)), BerkshelfVersion: aws.String(d.Get("berkshelf_version").(string)),
ManageBerkshelf: aws.Bool(d.Get("manage_berkshelf").(bool)), ManageBerkshelf: aws.Bool(d.Get("manage_berkshelf").(bool)),
} }
req.ConfigurationManager = &opsworks.StackConfigurationManager{ req.ConfigurationManager = &opsworks.StackConfigurationManager{
Name: aws.String(d.Get("configuration_manager_name").(string)), Name: aws.String(d.Get("configuration_manager_name").(string)),
Version: aws.String(d.Get("configuration_manager_version").(string)), Version: aws.String(d.Get("configuration_manager_version").(string)),