provider/aws: Read Elastic Beanstalk stack name (#7671)

This commit is contained in:
David Harris 2016-07-16 07:43:12 -06:00 committed by Paul Stack
parent 28561bd064
commit 03157610d8
1 changed files with 10 additions and 5 deletions

View File

@ -108,13 +108,14 @@ func resourceAwsElasticBeanstalkEnvironment() *schema.Resource {
Set: optionSettingValueHash, Set: optionSettingValueHash,
}, },
"solution_stack_name": &schema.Schema{ "solution_stack_name": &schema.Schema{
Type: schema.TypeString,
Optional: true,
},
"template_name": &schema.Schema{
Type: schema.TypeString, Type: schema.TypeString,
Optional: true, Optional: true,
ConflictsWith: []string{"solution_stack_name"}, Computed: true,
ConflictsWith: []string{"template_name"},
},
"template_name": &schema.Schema{
Type: schema.TypeString,
Optional: true,
}, },
"wait_for_ready_timeout": &schema.Schema{ "wait_for_ready_timeout": &schema.Schema{
Type: schema.TypeString, Type: schema.TypeString,
@ -420,6 +421,10 @@ func resourceAwsElasticBeanstalkEnvironmentRead(d *schema.ResourceData, meta int
} }
} }
if err := d.Set("solution_stack_name", env.SolutionStackName); err != nil {
return err
}
if err := d.Set("autoscaling_groups", flattenBeanstalkAsg(resources.EnvironmentResources.AutoScalingGroups)); err != nil { if err := d.Set("autoscaling_groups", flattenBeanstalkAsg(resources.EnvironmentResources.AutoScalingGroups)); err != nil {
return err return err
} }