This commit is contained in:
ioito
2019-05-21 21:29:05 +08:00
parent e878330938
commit d2c9c7d740
97 changed files with 2810 additions and 526 deletions
+21
View File
@@ -0,0 +1,21 @@
package shell
import (
"yunion.io/x/onecloud/pkg/util/shellutils"
"yunion.io/x/onecloud/pkg/util/zstack"
)
func init() {
type DiskListOptions struct {
StorageId string
DiskId string
}
shellutils.R(&DiskListOptions{}, "disk-list", "List disks", func(cli *zstack.SRegion, args *DiskListOptions) error {
disks, err := cli.GetDisks(args.StorageId, args.DiskId)
if err != nil {
return err
}
printList(disks, len(disks), 0, 0, []string{})
return nil
})
}