Skip to content

Commit

Permalink
fix: use curl error code to determine failure
Browse files Browse the repository at this point in the history
* The version of `curl` that we get in cflinuxfs4 appears to have a
  different error message when the connection times out.
* The error code is consistant accross versions, so use it.

Authored-by: Steve Taylor <[email protected]>
  • Loading branch information
staylor14 authored and ctlong committed Mar 28, 2023
1 parent 47a8f85 commit 394b7c5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tasks/task.go
Original file line number Diff line number Diff line change
Expand Up @@ -351,7 +351,7 @@ exit 1`
appLogs := logs.Recent(appName).Wait()
Expect(appLogs).To(Exit(0))
return string(appLogs.Out.Contents())
}, Config.CfPushTimeoutDuration()).Should(MatchRegexp("Connection timed out|No route to host"), "ASG configured to allow connection to the private IP but the app is still refused by private ip")
}, Config.CfPushTimeoutDuration()).Should(MatchRegexp(`curl: \(28\)|Connection timed out|No route to host`), "ASG configured to allow connection to the private IP but the app is still refused by private ip")
})
})
})
Expand Down

0 comments on commit 394b7c5

Please sign in to comment.