fix(compute/metadata): init a HTTP client in OnGCE check (#5439)
fix(compute/metadata): init a HTTP client in OnGCE check (#5439)

Initalize a resolver and http.Client locally in function to force
GC to cleanup background resources such as cached connections. This
can falsely report as leaked goroutines otherwise. This kind of issue
will still persist for calling methods like ProjectID, but we are
intentionally caching a client and its connections for these occations
today. If this ends up causing users issues in the fututure we can
reevaluate at that time.

Fixes: #5430
googleapis/google-cloud-go,googleapis/google-cloud-go,googleapis/google-cloud-go,googleapis/google-cloud-go