@utils.arg('size', metavar='<size>', type=int, help='Size of monitor in GB')
@utils.arg('--snapshot-id', metavar='<snapshot-id>', default=None, help='Create monitor from snapshot id (Optional, Default=None)')
@utils.arg('--snapshot_id', help=argparse.SUPPRESS)
@utils.arg('--source-volid', metavar='<source-volid>', default=None, help='Create monitor from monitor id (Optional, Default=None)')
@utils.arg('--source_volid', help=argparse.SUPPRESS)
@utils.arg('--image-id', metavar='<image-id>', default=None, help='Create monitor from image id (Optional, Default=None)')
@utils.arg('--image_id', help=argparse.SUPPRESS)
@utils.arg('--display-name', metavar='<display-name>', default=None, help='ServiceManage name (Optional, Default=None)')
@utils.arg('--display_name', help=argparse.SUPPRESS)
@utils.arg('--display-description', metavar='<display-description>', default=None, help='ServiceManage description (Optional, Default=None)')
@utils.arg('--display_description', help=argparse.SUPPRESS)
@utils.arg('--monitor-type', metavar='<monitor-type>', default=None, help='ServiceManage type (Optional, Default=None)')
@utils.arg('--monitor_type', help=argparse.SUPPRESS)
@utils.arg('--availability-zone', metavar='<availability-zone>', default=None, help='Availability zone for monitor (Optional, Default=None)')
@utils.arg('--availability_zone', help=argparse.SUPPRESS)
@utils.arg('--metadata', type=str, nargs='*', metavar='<key=value>', help='Metadata key=value pairs (Optional, Default=None)', default=None)
@utils.service_type('monitor')
def do_create(cs, args):
 monitor_metadata = None
 if (args.metadata is not None):
  monitor_metadata = _extract_metadata(args)
 monitor = cs.monitors.create(args.size, args.snapshot_id, args.source_volid, args.display_name, args.display_description, args.monitor_type, availability_zone=args.availability_zone, imageRef=args.image_id, metadata=monitor_metadata)
 _print_monitor(monitor)

@ utils . arg ( 'size' , metavar = '<size>' , type = int , help = 'Size of monitor in GB' ) @ utils . arg ( '--snapshot-id' , metavar = '<snapshot-id>' , default = None , help = 'Create monitor from snapshot id (Optional, Default=None)' ) @ utils . arg ( '--snapshot_id' , help = argparse . SUPPRESS ) @ utils . arg ( '--source-volid' , metavar = '<source-volid>' , default = None , help = 'Create monitor from monitor id (Optional, Default=None)' ) @ utils . arg ( '--source_volid' , help = argparse . SUPPRESS ) @ utils . arg ( '--image-id' , metavar = '<image-id>' , default = None , help = 'Create monitor from image id (Optional, Default=None)' ) @ utils . arg ( '--image_id' , help = argparse . SUPPRESS ) @ utils . arg ( '--display-name' , metavar = '<display-name>' , default = None , help = 'ServiceManage name (Optional, Default=None)' ) @ utils . arg ( '--display_name' , help = argparse . SUPPRESS ) @ utils . arg ( '--display-description' , metavar = '<display-description>' , default = None , help = 'ServiceManage description (Optional, Default=None)' ) @ utils . arg ( '--display_description' , help = argparse . SUPPRESS ) @ utils . arg ( '--monitor-type' , metavar = '<monitor-type>' , default = None , help = 'ServiceManage type (Optional, Default=None)' ) @ utils . arg ( '--monitor_type' , help = argparse . SUPPRESS ) @ utils . arg ( '--availability-zone' , metavar = '<availability-zone>' , default = None , help = 'Availability zone for monitor (Optional, Default=None)' ) @ utils . arg ( '--availability_zone' , help = argparse . SUPPRESS ) @ utils . arg ( '--metadata' , type = str , nargs = '*' , metavar = '<key=value>' , help = 'Metadata key=value pairs (Optional, Default=None)' , default = None ) @ utils . service_type ( 'monitor' ) def do_create ( cs , args ) : monitor_metadata = None if ( args . metadata is not None ) : monitor_metadata = _extract_metadata ( args ) monitor = cs . monitors . create ( args . size , args . snapshot_id , args . source_volid , args . display_name , args . display_description , args . monitor_type , availability_zone = args . availability_zone , imageRef = args . image_id , metadata = monitor_metadata ) _print_monitor ( monitor )
create a installer script for each variant in bootstrap_dict .