- make_option("-n", "--new-secondary", dest="new_secondary",
- help=("New secondary node (for secondary"
- " node change)"), metavar="NODE",
- default=None),
- make_option("-p", "--on-primary", dest="on_primary",
- default=False, action="store_true",
- help=("Replace the disk(s) on the primary"
- " node (only for the drbd template)")),
- make_option("-s", "--on-secondary", dest="on_secondary",
- default=False, action="store_true",
- help=("Replace the disk(s) on the secondary"
- " node (only for the drbd template)")),
- make_option("--disks", dest="disks", default=None,
- help="Comma-separated list of disks"
- " indices to replace (e.g. 0,2) (optional,"
- " defaults to all disks)"),
- make_option("-I", "--iallocator", metavar="<NAME>",
- help="Select new secondary for the instance"
- " automatically using the"
- " <NAME> iallocator plugin (enables"
- " secondary node replacement)",
- default=None, type="string"),
+ cli_option("-n", "--new-secondary", dest="new_secondary",
+ help=("New secondary node (for secondary"
+ " node change)"), metavar="NODE",
+ default=None,
+ completion_suggest=OPT_COMPL_ONE_NODE),
+ cli_option("-p", "--on-primary", dest="on_primary",
+ default=False, action="store_true",
+ help=("Replace the disk(s) on the primary"
+ " node (only for the drbd template)")),
+ cli_option("-s", "--on-secondary", dest="on_secondary",
+ default=False, action="store_true",
+ help=("Replace the disk(s) on the secondary"
+ " node (only for the drbd template)")),
+ cli_option("-a", "--auto", dest="auto",
+ default=False, action="store_true",
+ help=("Automatically replace faulty disks"
+ " (only for the drbd template)")),
+ cli_option("--disks", dest="disks", default=None,
+ help="Comma-separated list of disks"
+ " indices to replace (e.g. 0,2) (optional,"
+ " defaults to all disks)"),
+ cli_option("-I", "--iallocator", metavar="<NAME>",
+ help="Select new secondary for the instance"
+ " automatically using the"
+ " <NAME> iallocator plugin (enables"
+ " secondary node replacement)",
+ default=None, type="string",
+ completion_suggest=OPT_COMPL_ONE_IALLOCATOR),