Skip to content
This repository has been archived by the owner on Oct 23, 2020. It is now read-only.

Commit

Permalink
fix some import bug
Browse files Browse the repository at this point in the history
  • Loading branch information
remijouannet committed Feb 15, 2018
1 parent 7d441e4 commit 123659d
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions osc/import_osc_route_table.go
Original file line number Diff line number Diff line change
Expand Up @@ -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))
Expand All @@ -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)
Expand All @@ -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)
Expand Down
2 changes: 1 addition & 1 deletion osc/import_osc_s3_bucket.go
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand Down
2 changes: 1 addition & 1 deletion osc/import_osc_security_group.go
Original file line number Diff line number Diff line change
Expand Up @@ -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)

Expand Down

0 comments on commit 123659d

Please sign in to comment.