provider/aws: Add arn to DB Instance output

This commit is contained in:
clint shryock 2015-12-08 10:52:17 -06:00
parent 1cd2fea1f9
commit 0619898f6a
2 changed files with 7 additions and 0 deletions

View File

@ -31,6 +31,11 @@ func resourceAwsDbInstance() *schema.Resource {
ForceNew: true,
},
"arn": &schema.Schema{
Type: schema.TypeString,
Computed: true,
},
"username": &schema.Schema{
Type: schema.TypeString,
Required: true,
@ -553,6 +558,7 @@ func resourceAwsDbInstanceRead(d *schema.ResourceData, meta interface{}) error {
}
log.Printf("[DEBUG] Error building ARN for DB Instance, not setting Tags for DB %s", name)
} else {
d.Set("arn", arn)
resp, err := conn.ListTagsForResource(&rds.ListTagsForResourceInput{
ResourceName: aws.String(arn),
})

View File

@ -93,6 +93,7 @@ The following attributes are exported:
* `id` - The RDS instance ID.
* `address` - The address of the RDS instance.
* `arn` - The ARN of the RDS instance.
* `allocated_storage` - The amount of allocated storage
* `availability_zone` - The availability zone of the instance
* `backup_retention_period` - The backup retention period