Skip to content

Commit

Permalink
fix remarks for spot_fleet_request
Browse files Browse the repository at this point in the history
  • Loading branch information
svenwltr committed Jul 28, 2017
1 parent e1be687 commit 22ecb1c
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions aws/resource_aws_spot_fleet_request.go
Original file line number Diff line number Diff line change
Expand Up @@ -638,8 +638,8 @@ func resourceAwsSpotFleetRequestCreate(d *schema.ResourceData, meta interface{})
spotStateConf := &resource.StateChangeConf{
Pending: []string{"pending_fulfillment"},
Target: []string{"fulfilled"},
Refresh: resourceAwsSpotFleetRequestFulfillmentRefreshFunc(d, meta),
Timeout: 10 * time.Minute,
Refresh: resourceAwsSpotFleetRequestFulfillmentRefreshFunc(d.Id(), meta.(*AWSClient).ec2conn),
Timeout: d.Timeout(schema.TimeoutCreate),
Delay: 10 * time.Second,
MinTimeout: 3 * time.Second,
}
Expand Down Expand Up @@ -681,11 +681,10 @@ func resourceAwsSpotFleetRequestStateRefreshFunc(d *schema.ResourceData, meta in
}
}

func resourceAwsSpotFleetRequestFulfillmentRefreshFunc(d *schema.ResourceData, meta interface{}) resource.StateRefreshFunc {
func resourceAwsSpotFleetRequestFulfillmentRefreshFunc(id string, conn *ec2.EC2) resource.StateRefreshFunc {
return func() (interface{}, string, error) {
conn := meta.(*AWSClient).ec2conn
req := &ec2.DescribeSpotFleetRequestsInput{
SpotFleetRequestIds: []*string{aws.String(d.Id())},
SpotFleetRequestIds: []*string{aws.String(id)},
}
resp, err := conn.DescribeSpotFleetRequests(req)

Expand Down

0 comments on commit 22ecb1c

Please sign in to comment.