summaryrefslogtreecommitdiff
path: root/main.go
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2024-10-31 06:50:17 -0500
committerJeff Carr <[email protected]>2024-10-31 06:50:17 -0500
commita345a813d887b02d9c6eaea9d4645cf5c30f0573 (patch)
treeb10b29c7d9d42673a126b62892f8b56df7aac87f /main.go
parentcc092bd8955ce7589fb2d92c091a5da3f8f714e5 (diff)
rename to virtigolib
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'main.go')
-rw-r--r--main.go7
1 files changed, 3 insertions, 4 deletions
diff --git a/main.go b/main.go
index 0c4f04a..3ef9aab 100644
--- a/main.go
+++ b/main.go
@@ -26,7 +26,6 @@ import (
)
var Version string
-var hv *hypervisor.Hypervisor
//go:embed resources/*
var resources embed.FS
@@ -46,15 +45,15 @@ func main() {
// fmt.Printf("\nConnecting to %s://%s\n", *network, *address)
newConn := func() (net.Conn, error) {
+ // return net.DialTimeout("tcp", "hyper02:16514", *timeout)
// return net.DialTimeout(*network, *address, *timeout)
return net.DialTimeout("unix", "/var/run/libvirt/libvirt-sock", 2*time.Second)
- // return net.DialTimeout("tcp", "farm02:16514", *timeout)
}
driver := hypervisor.NewRPCDriver(newConn)
- hv = hypervisor.New(driver)
+ me.hv = hypervisor.New(driver)
- pollHypervisor(hv)
+ pollHypervisor(me.hv)
startHTTP()
}