Merge branch 'master' of github.com:hashicorp/terraform

* 'master' of github.com:hashicorp/terraform:
  Update CHANGELOG.md
  providers/heroku: import heroku_addon resource (#14508)
This commit is contained in:
clint shryock 2017-05-24 14:26:58 -05:00
commit cf1ef167fe
2 changed files with 6 additions and 2 deletions

View File

@ -61,6 +61,7 @@ IMPROVEMENTS:
* provider/google: resource_compute_disks can now reference snapshots using the snapshot URL [GH-14774]
* provider/heroku: Add import support for `heroku_pipeline` resource [GH-14486]
* provider/heroku: Add import support for `heroku_pipeline_coupling` resource [GH-14495]
* providers/heroku: Add import support for `heroku_addon` resource [GH-14508]
* provider/openstack: Add support for all protocols in Security Group Rules [GH-14307]
* provider/openstack: Add support for updating Subnet Allocation Pools [GH-14782]
* provider/rancher: Add member support to `rancher_environment` [GH-14563]

View File

@ -25,6 +25,10 @@ func resourceHerokuAddon() *schema.Resource {
Update: resourceHerokuAddonUpdate,
Delete: resourceHerokuAddonDelete,
Importer: &schema.ResourceImporter{
State: schema.ImportStatePassthrough,
},
Schema: map[string]*schema.Schema{
"app": {
Type: schema.TypeString,
@ -111,8 +115,7 @@ func resourceHerokuAddonCreate(d *schema.ResourceData, meta interface{}) error {
func resourceHerokuAddonRead(d *schema.ResourceData, meta interface{}) error {
client := meta.(*heroku.Service)
addon, err := resourceHerokuAddonRetrieveByApp(
d.Get("app").(string), d.Id(), client)
addon, err := resourceHerokuAddonRetrieve(d.Id(), client)
if err != nil {
return err
}