cleanup STDOUT logging
Signed-off-by: Jeff Carr <jcarr@wit.com>
This commit is contained in:
parent
caf84a6326
commit
6c236628b1
|
@ -33,7 +33,7 @@ func addDomainDroplet(domcfg *libvirtxml.Domain) (*DropletT, error) {
|
|||
if me.changed {
|
||||
log.Info("updateDroplet() worked. droplet changed")
|
||||
} else {
|
||||
log.Info("updateDroplet() worked. nothing changed")
|
||||
log.Verbose("updateDroplet() worked. nothing changed")
|
||||
}
|
||||
} else {
|
||||
log.Info("updateDroplet() failed for", d.pb.Hostname)
|
||||
|
@ -182,7 +182,7 @@ func updateNetwork(d *DropletT, domcfg *libvirtxml.Domain) bool {
|
|||
var found bool = false
|
||||
for i, eth := range d.pb.Networks {
|
||||
if eth.Mac == mac {
|
||||
log.Info("OKAY. FOUND ETH:", i, eth.Mac, eth.Name)
|
||||
log.Verbose("OKAY. FOUND ETH:", i, eth.Mac, eth.Name)
|
||||
found = true
|
||||
}
|
||||
}
|
||||
|
@ -196,7 +196,7 @@ func updateNetwork(d *DropletT, domcfg *libvirtxml.Domain) bool {
|
|||
}
|
||||
}
|
||||
|
||||
log.Info("mac addrs:", macs)
|
||||
log.Verbose("mac addrs:", macs)
|
||||
return true
|
||||
}
|
||||
|
||||
|
@ -217,7 +217,7 @@ func updateDisk(d *DropletT, domcfg *libvirtxml.Domain) bool {
|
|||
var found bool = false
|
||||
for _, disk := range d.pb.Disks {
|
||||
if disk.Filename == filename {
|
||||
log.Info("OKAY. FOUND filename", filename)
|
||||
log.Verbose("OKAY. FOUND filename", filename)
|
||||
found = true
|
||||
}
|
||||
}
|
||||
|
|
2
main.go
2
main.go
|
@ -73,7 +73,7 @@ func main() {
|
|||
if me.changed {
|
||||
log.Info("updateDroplet() worked. droplet changed")
|
||||
} else {
|
||||
log.Info("updateDroplet() worked. nothing changed")
|
||||
log.Info(filename, "nothing changed")
|
||||
}
|
||||
} else {
|
||||
log.Info("updateDroplet() failed for", d.pb.Hostname)
|
||||
|
|
4
xml.go
4
xml.go
|
@ -72,7 +72,7 @@ func addDefaults(d *libvirtxml.Domain, filename string) {
|
|||
}
|
||||
|
||||
func readXml(filename string) (*libvirtxml.Domain, error) {
|
||||
log.Info("parse xml file:", filename)
|
||||
log.Verbose("parse xml file:", filename)
|
||||
|
||||
pfile, err := os.ReadFile(filename)
|
||||
if err != nil {
|
||||
|
@ -91,7 +91,7 @@ func readXml(filename string) (*libvirtxml.Domain, error) {
|
|||
}
|
||||
|
||||
func (d *DropletT) mergeXml(filename string) error {
|
||||
log.Info("parse xml file:", filename)
|
||||
log.Info("merge xml file:", filename)
|
||||
|
||||
pfile, err := os.ReadFile(filename)
|
||||
if err != nil {
|
||||
|
|
Loading…
Reference in New Issue