From 123659dd904b4c276dda8bb8c888610102ebe213 Mon Sep 17 00:00:00 2001 From: remijouannet Date: Fri, 16 Feb 2018 00:06:56 +0100 Subject: [PATCH] fix some import bug --- osc/import_osc_route_table.go | 6 +++--- osc/import_osc_s3_bucket.go | 2 +- osc/import_osc_security_group.go | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/osc/import_osc_route_table.go b/osc/import_osc_route_table.go index 402b8d5a..069a284b 100644 --- a/osc/import_osc_route_table.go +++ b/osc/import_osc_route_table.go @@ -48,7 +48,7 @@ func resourceAwsRouteTableImportState( // Minimal data for route d := subResource.Data(nil) - d.SetType("aws_route") + d.SetType("osc_route") d.Set("route_table_id", id) d.Set("destination_cidr_block", route.DestinationCidrBlock) d.SetId(routeIDHash(d, route)) @@ -67,7 +67,7 @@ func resourceAwsRouteTableImportState( // Minimal data for route d := subResource.Data(nil) - d.SetType("aws_route_table_association") + d.SetType("osc_route_table_association") d.Set("route_table_id", assoc.RouteTableId) d.SetId(*assoc.RouteTableAssociationId) results = append(results, d) @@ -86,7 +86,7 @@ func resourceAwsRouteTableImportState( // Minimal data for route d := subResource.Data(nil) - d.SetType("aws_main_route_table_association") + d.SetType("osc_main_route_table_association") d.Set("route_table_id", id) d.Set("vpc_id", table.VpcId) d.SetId(*assoc.RouteTableAssociationId) diff --git a/osc/import_osc_s3_bucket.go b/osc/import_osc_s3_bucket.go index ee7201c9..de2f9fce 100644 --- a/osc/import_osc_s3_bucket.go +++ b/osc/import_osc_s3_bucket.go @@ -30,7 +30,7 @@ func resourceAwsS3BucketImportState( policy := resourceAwsS3BucketPolicy() pData := policy.Data(nil) pData.SetId(d.Id()) - pData.SetType("aws_s3_bucket_policy") + pData.SetType("osc_s3_bucket_policy") pData.Set("bucket", d.Id()) pData.Set("policy", pol) results = append(results, pData) diff --git a/osc/import_osc_security_group.go b/osc/import_osc_security_group.go index 0ed6196f..0d962cc4 100644 --- a/osc/import_osc_security_group.go +++ b/osc/import_osc_security_group.go @@ -93,7 +93,7 @@ func resourceAwsSecurityGroupImportStatePermPair(sg *ec2.SecurityGroup, ruleType ruleResource := resourceAwsSecurityGroupRule() d := ruleResource.Data(nil) d.SetId(id) - d.SetType("aws_security_group_rule") + d.SetType("osc_security_group_rule") d.Set("security_group_id", sgId) d.Set("type", ruleType)