Merge branch 'freeman-master'
This commit is contained in:
commit
5dac56629d
|
@ -236,6 +236,11 @@ func resourceAwsDbInstance() *schema.Resource {
|
||||||
Computed: true,
|
Computed: true,
|
||||||
},
|
},
|
||||||
|
|
||||||
|
"hosted_zone_id": &schema.Schema{
|
||||||
|
Type: schema.TypeString,
|
||||||
|
Computed: true,
|
||||||
|
},
|
||||||
|
|
||||||
"status": &schema.Schema{
|
"status": &schema.Schema{
|
||||||
Type: schema.TypeString,
|
Type: schema.TypeString,
|
||||||
Computed: true,
|
Computed: true,
|
||||||
|
@ -669,7 +674,7 @@ func resourceAwsDbInstanceRead(d *schema.ResourceData, meta interface{}) error {
|
||||||
if v.Endpoint != nil {
|
if v.Endpoint != nil {
|
||||||
d.Set("port", v.Endpoint.Port)
|
d.Set("port", v.Endpoint.Port)
|
||||||
d.Set("address", v.Endpoint.Address)
|
d.Set("address", v.Endpoint.Address)
|
||||||
|
d.Set("hosted_zone_id", v.Endpoint.HostedZoneId)
|
||||||
if v.Endpoint.Address != nil && v.Endpoint.Port != nil {
|
if v.Endpoint.Address != nil && v.Endpoint.Port != nil {
|
||||||
d.Set("endpoint",
|
d.Set("endpoint",
|
||||||
fmt.Sprintf("%s:%d", *v.Endpoint.Address, *v.Endpoint.Port))
|
fmt.Sprintf("%s:%d", *v.Endpoint.Address, *v.Endpoint.Port))
|
||||||
|
|
|
@ -46,6 +46,7 @@ func TestAccAWSDBInstance_basic(t *testing.T) {
|
||||||
"aws_db_instance.bar", "username", "foo"),
|
"aws_db_instance.bar", "username", "foo"),
|
||||||
resource.TestCheckResourceAttr(
|
resource.TestCheckResourceAttr(
|
||||||
"aws_db_instance.bar", "parameter_group_name", "default.mysql5.6"),
|
"aws_db_instance.bar", "parameter_group_name", "default.mysql5.6"),
|
||||||
|
resource.TestCheckResourceAttrSet("aws_db_instance.bar", "hosted_zone_id"),
|
||||||
),
|
),
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
|
@ -136,6 +136,7 @@ The following attributes are exported:
|
||||||
* `status` - The RDS instance status
|
* `status` - The RDS instance status
|
||||||
* `username` - The master username for the database
|
* `username` - The master username for the database
|
||||||
* `storage_encrypted` - Specifies whether the DB instance is encrypted
|
* `storage_encrypted` - Specifies whether the DB instance is encrypted
|
||||||
|
* `zone_id` - The canonical hosted zone ID of the DB instance (to be used in a Route 53 Alias record)
|
||||||
|
|
||||||
On Oracle instances the following is exported additionally:
|
On Oracle instances the following is exported additionally:
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue