mirror of
https://git.uploadfilter24.eu/lerentis/terraform-provider-gitea.git
synced 2024-11-13 05:28:12 +00:00
12 lines
214 B
Go
12 lines
214 B
Go
package sprig
|
|
|
|
import (
|
|
"math/rand"
|
|
"net"
|
|
)
|
|
|
|
func getHostByName(name string) string {
|
|
addrs, _ := net.LookupHost(name)
|
|
//TODO: add error handing when release v3 cames out
|
|
return addrs[rand.Intn(len(addrs))]
|
|
}
|