parent
ec9d464997
commit
a1feb086a6
2
argv.go
2
argv.go
|
@ -28,6 +28,8 @@ type ImportXml struct {
|
|||
IgnoreCpu bool `arg:"--xml-ignore-cpu" default:"true" help:"ignore non-standard libvirt xml cpus"`
|
||||
IgnoreBr bool `arg:"--xml-ignore-net" default:"true" help:"ignore network bridge name changes"`
|
||||
IgnDisk bool `arg:"--xml-ignore-disk" default:"false" help:"ignore duplicate disk names"`
|
||||
DomainName string `arg:"--name" help:"virsh domain name"`
|
||||
Host string `arg:"--host" help:"hypervisor hostname"`
|
||||
}
|
||||
|
||||
type args struct {
|
||||
|
|
9
main.go
9
main.go
|
@ -48,6 +48,7 @@ func main() {
|
|||
log.Info("dump something here")
|
||||
os.Exit(0)
|
||||
}
|
||||
|
||||
if argv.Create != nil {
|
||||
dir := filepath.Dir(argv.Create.Filename)
|
||||
filename := filepath.Base(argv.Create.Filename)
|
||||
|
@ -58,10 +59,18 @@ func main() {
|
|||
log.Info("virtigoctl create end")
|
||||
os.Exit(0)
|
||||
}
|
||||
|
||||
if argv.Start != nil {
|
||||
log.Info("start the vm's here:", argv.Start)
|
||||
os.Exit(0)
|
||||
}
|
||||
|
||||
if argv.Import != nil {
|
||||
log.Info("should import here", argv.Start)
|
||||
log.Info("virtigoctl import --host farm04 --name grafana")
|
||||
log.Info("import", argv.Import.Host, argv.Import.DomainName)
|
||||
os.Exit(0)
|
||||
}
|
||||
}
|
||||
|
||||
func dumpDroplets(full bool) error {
|
||||
|
|
Loading…
Reference in New Issue