openstackclient.compute.v2 package
openstackclient.compute.v2.agent module
Agent action implementations
-
class openstackclient.compute.v2.agent.CreateAgent(app, app_args, cmd_name=None)
Bases: ShowOne
Create compute agent.
The compute agent functionality is hypervisor specific and is only
supported by the XenAPI hypervisor driver. It was removed from nova in the
23.0.0 (Wallaby) release.
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.agent.CreateAgent (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
-
class openstackclient.compute.v2.agent.DeleteAgent(app, app_args, cmd_name=None)
Bases: Command
Delete compute agent(s).
The compute agent functionality is hypervisor specific and is only
supported by the XenAPI hypervisor driver. It was removed from nova in the
23.0.0 (Wallaby) release.
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.agent.DeleteAgent (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.agent.ListAgent(app, app_args, cmd_name=None)
Bases: Lister
List compute agents.
The compute agent functionality is hypervisor specific and is only
supported by the XenAPI hypervisor driver. It was removed from nova in the
23.0.0 (Wallaby) release.
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.agent.ListAgent (WARNING)>
-
take_action(parsed_args)
Run command.
Return a tuple containing the column names and an iterable containing
the data to be listed.
-
class openstackclient.compute.v2.agent.SetAgent(app, app_args, cmd_name=None)
Bases: Command
Set compute agent properties.
The compute agent functionality is hypervisor specific and is only
supported by the XenAPI hypervisor driver. It was removed from nova in the
23.0.0 (Wallaby) release.
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.agent.SetAgent (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
openstackclient.compute.v2.aggregate module
Compute v2 Aggregate action implementations
-
class openstackclient.compute.v2.aggregate.AddAggregateHost(app, app_args, cmd_name=None)
Bases: ShowOne
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.aggregate.AddAggregateHost (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
-
class openstackclient.compute.v2.aggregate.CacheImageForAggregate(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.aggregate.CacheImageForAggregate (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.aggregate.CreateAggregate(app, app_args, cmd_name=None)
Bases: ShowOne
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.aggregate.CreateAggregate (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
-
class openstackclient.compute.v2.aggregate.DeleteAggregate(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.aggregate.DeleteAggregate (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.aggregate.ListAggregate(app, app_args, cmd_name=None)
Bases: Lister
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.aggregate.ListAggregate (WARNING)>
-
take_action(parsed_args)
Run command.
Return a tuple containing the column names and an iterable containing
the data to be listed.
-
class openstackclient.compute.v2.aggregate.RemoveAggregateHost(app, app_args, cmd_name=None)
Bases: ShowOne
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.aggregate.RemoveAggregateHost (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
-
class openstackclient.compute.v2.aggregate.SetAggregate(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.aggregate.SetAggregate (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.aggregate.ShowAggregate(app, app_args, cmd_name=None)
Bases: ShowOne
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.aggregate.ShowAggregate (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
-
class openstackclient.compute.v2.aggregate.UnsetAggregate(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.aggregate.UnsetAggregate (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
openstackclient.compute.v2.console module
Compute v2 Console action implementations
-
class openstackclient.compute.v2.console.ShowConsoleLog(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.console.ShowConsoleLog (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.console.ShowConsoleURL(app, app_args, cmd_name=None)
Bases: ShowOne
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.console.ShowConsoleURL (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
openstackclient.compute.v2.flavor module
Flavor action implementations
-
class openstackclient.compute.v2.flavor.CreateFlavor(app, app_args, cmd_name=None)
Bases: ShowOne
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.flavor.CreateFlavor (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
-
class openstackclient.compute.v2.flavor.DeleteFlavor(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.flavor.DeleteFlavor (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.flavor.ListFlavor(app, app_args, cmd_name=None)
Bases: Lister
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.flavor.ListFlavor (WARNING)>
-
take_action(parsed_args)
Run command.
Return a tuple containing the column names and an iterable containing
the data to be listed.
-
class openstackclient.compute.v2.flavor.SetFlavor(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.flavor.SetFlavor (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.flavor.ShowFlavor(app, app_args, cmd_name=None)
Bases: ShowOne
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.flavor.ShowFlavor (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
-
class openstackclient.compute.v2.flavor.UnsetFlavor(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.flavor.UnsetFlavor (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
openstackclient.compute.v2.host module
Host action implementations
-
class openstackclient.compute.v2.host.ListHost(app, app_args, cmd_name=None)
Bases: Lister
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.host.ListHost (WARNING)>
-
take_action(parsed_args)
Run command.
Return a tuple containing the column names and an iterable containing
the data to be listed.
-
class openstackclient.compute.v2.host.SetHost(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.host.SetHost (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.host.ShowHost(app, app_args, cmd_name=None)
Bases: Lister
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.host.ShowHost (WARNING)>
-
take_action(parsed_args)
Run command.
Return a tuple containing the column names and an iterable containing
the data to be listed.
openstackclient.compute.v2.hypervisor module
Hypervisor action implementations
-
class openstackclient.compute.v2.hypervisor.ListHypervisor(app, app_args, cmd_name=None)
Bases: Lister
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.hypervisor.ListHypervisor (WARNING)>
-
take_action(parsed_args)
Run command.
Return a tuple containing the column names and an iterable containing
the data to be listed.
-
class openstackclient.compute.v2.hypervisor.ShowHypervisor(app, app_args, cmd_name=None)
Bases: ShowOne
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.hypervisor.ShowHypervisor (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
openstackclient.compute.v2.hypervisor_stats module
Hypervisor Stats action implementations
-
class openstackclient.compute.v2.hypervisor_stats.ShowHypervisorStats(app, app_args, cmd_name=None)
Bases: ShowOne
-
log = <Logger openstackclient.compute.v2.hypervisor_stats.ShowHypervisorStats (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
openstackclient.compute.v2.keypair module
Keypair action implementations
-
class openstackclient.compute.v2.keypair.CreateKeypair(app, app_args, cmd_name=None)
Bases: ShowOne
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.keypair.CreateKeypair (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
-
class openstackclient.compute.v2.keypair.DeleteKeypair(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.keypair.DeleteKeypair (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.keypair.ListKeypair(app, app_args, cmd_name=None)
Bases: Lister
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.keypair.ListKeypair (WARNING)>
-
take_action(parsed_args)
Run command.
Return a tuple containing the column names and an iterable containing
the data to be listed.
-
class openstackclient.compute.v2.keypair.ShowKeypair(app, app_args, cmd_name=None)
Bases: ShowOne
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.keypair.ShowKeypair (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
openstackclient.compute.v2.server module
Compute v2 Server action implementations
-
class openstackclient.compute.v2.server.AddFixedIP(app, app_args, cmd_name=None)
Bases: ShowOne
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.AddFixedIP (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
-
class openstackclient.compute.v2.server.AddFloatingIP(app, app_args, cmd_name=None)
Bases: NetworkAndComputeCommand
-
log = <Logger openstackclient.compute.v2.server.AddFloatingIP (WARNING)>
-
take_action_compute(client, parsed_args)
Override to do something useful.
-
take_action_network(client, parsed_args)
Override to do something useful.
-
update_parser_common(parser)
Default is no updates to parser.
-
class openstackclient.compute.v2.server.AddNetwork(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.AddNetwork (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.AddPort(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.AddPort (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.AddServerSecurityGroup(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.AddServerSecurityGroup (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.AddServerVolume(app, app_args, cmd_name=None)
Bases: ShowOne
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.AddServerVolume (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
-
class openstackclient.compute.v2.server.BDMAction(option_strings, dest, **kwargs)
Bases: MultiKeyValueAction
-
validate_keys(keys)
Validate the provided keys.
- Parameters:
keys – A list of keys to validate.
-
class openstackclient.compute.v2.server.BDMLegacyAction(option_strings, dest, nargs=None, const=None, default=None, type=None, choices=None, required=False, help=None, metavar=None)
Bases: Action
-
class openstackclient.compute.v2.server.ConfirmMigration(app, app_args, cmd_name=None)
Bases: ResizeConfirm
-
log = <Logger openstackclient.compute.v2.server.ConfirmMigration (WARNING)>
-
class openstackclient.compute.v2.server.CreateServer(app, app_args, cmd_name=None)
Bases: ShowOne
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.CreateServer (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
-
class openstackclient.compute.v2.server.CreateServerDump(app, app_args, cmd_name=None)
Bases: Command
Create a dump file in server(s)
Trigger crash dump in server(s) with features like kdump in Linux.
It will create a dump file in the server(s) dumping the server(s)’
memory, and also crash the server(s). OSC sees the dump file
(server dump) as a kind of resource.
This command requires --os-compute-api-version
2.17 or greater.
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.CreateServerDump (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.DeleteServer(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.DeleteServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.EvacuateServer(app, app_args, cmd_name=None)
Bases: ShowOne
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.EvacuateServer (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
-
class openstackclient.compute.v2.server.ListServer(app, app_args, cmd_name=None)
Bases: Lister
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.ListServer (WARNING)>
-
take_action(parsed_args)
Run command.
Return a tuple containing the column names and an iterable containing
the data to be listed.
-
class openstackclient.compute.v2.server.LockServer(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.LockServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.MigrateConfirm(app, app_args, cmd_name=None)
Bases: ResizeConfirm
-
log = <Logger openstackclient.compute.v2.server.MigrateConfirm (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.MigrateRevert(app, app_args, cmd_name=None)
Bases: ResizeRevert
-
log = <Logger openstackclient.compute.v2.server.MigrateRevert (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.MigrateServer(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.MigrateServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.NICAction(option_strings, dest, nargs=None, const=None, default=None, type=None, choices=None, required=False, help=None, metavar=None, key=None)
Bases: Action
-
class openstackclient.compute.v2.server.PauseServer(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.PauseServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.PowerStateColumn(value)
Bases: FormattableColumn
Generate a formatted string of a server’s power state.
-
human_readable()
Return a basic human readable version of the data.
-
power_states = ['NOSTATE', 'Running', '', 'Paused', 'Shutdown', '', 'Crashed', 'Suspended']
-
class openstackclient.compute.v2.server.RebootServer(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.RebootServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.RebuildServer(app, app_args, cmd_name=None)
Bases: ShowOne
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.RebuildServer (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
-
class openstackclient.compute.v2.server.RemoveFixedIP(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.RemoveFixedIP (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.RemoveFloatingIP(app, app_args, cmd_name=None)
Bases: NetworkAndComputeCommand
-
log = <Logger openstackclient.compute.v2.server.RemoveFloatingIP (WARNING)>
-
take_action_compute(client, parsed_args)
Override to do something useful.
-
take_action_network(client, parsed_args)
Override to do something useful.
-
update_parser_common(parser)
Default is no updates to parser.
-
class openstackclient.compute.v2.server.RemoveNetwork(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.RemoveNetwork (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.RemovePort(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.RemovePort (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.RemoveServerSecurityGroup(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.RemoveServerSecurityGroup (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.RemoveServerVolume(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.RemoveServerVolume (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.RescueServer(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.RescueServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.ResizeConfirm(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.ResizeConfirm (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.ResizeRevert(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.ResizeRevert (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.ResizeServer(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.ResizeServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.RestoreServer(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.RestoreServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.ResumeServer(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.ResumeServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.RevertMigration(app, app_args, cmd_name=None)
Bases: ResizeRevert
-
log = <Logger openstackclient.compute.v2.server.RevertMigration (WARNING)>
-
class openstackclient.compute.v2.server.SetServer(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.SetServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.ShelveServer(app, app_args, cmd_name=None)
Bases: Command
Shelve and optionally offload server(s).
Shelving a server creates a snapshot of the server and stores this
snapshot before shutting down the server. This shelved server can then be
offloaded or deleted from the host, freeing up remaining resources on the
host, such as network interfaces. Shelved servers can be unshelved,
restoring the server from the snapshot. Shelving is therefore useful where
users wish to retain the UUID and IP of a server, without utilizing other
resources or disks.
Most clouds are configured to automatically offload shelved servers
immediately or after a small delay. For clouds where this is not
configured, or where the delay is larger, offloading can be manually
specified. This is an admin-only operation by default.
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.ShelveServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.ShowServer(app, app_args, cmd_name=None)
Bases: ShowOne
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.ShowServer (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
-
class openstackclient.compute.v2.server.SshServer(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.SshServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.StartServer(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.StartServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.StopServer(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.StopServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.SuspendServer(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.SuspendServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.UnlockServer(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.UnlockServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.UnpauseServer(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.UnpauseServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.UnrescueServer(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.UnrescueServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.UnsetServer(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.UnsetServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server.UnshelveServer(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server.UnshelveServer (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
openstackclient.compute.v2.server.boolenv(*vars, default=False)
Search for the first defined of possibly many bool-like env vars.
Returns the first environment variable defined in vars, or returns the
default.
- Parameters:
-
- Returns:
A boolean corresponding to the value found, else the default if
no value found.
-
openstackclient.compute.v2.server.percent_type(x)
openstackclient.compute.v2.server_backup module
Compute v2 Server action implementations
-
class openstackclient.compute.v2.server_backup.CreateServerBackup(app, app_args, cmd_name=None)
Bases: ShowOne
-
IMAGE_API_VERSIONS = {'1': 'openstackclient.image.v1.image', '2': 'openstackclient.image.v2.image'}
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server_backup.CreateServerBackup (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
openstackclient.compute.v2.server_event module
Compute v2 Server operation event implementations
-
class openstackclient.compute.v2.server_event.ListServerEvent(app, app_args, cmd_name=None)
Bases: Lister
List recent events of a server.
Specify --os-compute-api-version 2.21
or higher to show events for a
deleted server, specified by ID only.
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server_event.ListServerEvent (WARNING)>
-
take_action(parsed_args)
Run command.
Return a tuple containing the column names and an iterable containing
the data to be listed.
-
class openstackclient.compute.v2.server_event.ShowServerEvent(app, app_args, cmd_name=None)
Bases: ShowOne
Show server event details.
Specify --os-compute-api-version 2.21
or higher to show event details
for a deleted server, specified by ID only. Specify
--os-compute-api-version 2.51
or higher to show event details for
non-admin users.
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server_event.ShowServerEvent (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
openstackclient.compute.v2.server_group module
Compute v2 Server Group action implementations
-
class openstackclient.compute.v2.server_group.CreateServerGroup(app, app_args, cmd_name=None)
Bases: ShowOne
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server_group.CreateServerGroup (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
-
class openstackclient.compute.v2.server_group.DeleteServerGroup(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server_group.DeleteServerGroup (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server_group.ListServerGroup(app, app_args, cmd_name=None)
Bases: Lister
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server_group.ListServerGroup (WARNING)>
-
take_action(parsed_args)
Run command.
Return a tuple containing the column names and an iterable containing
the data to be listed.
-
class openstackclient.compute.v2.server_group.ShowServerGroup(app, app_args, cmd_name=None)
Bases: ShowOne
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server_group.ShowServerGroup (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
openstackclient.compute.v2.server_image module
Compute v2 Server action implementations
-
class openstackclient.compute.v2.server_image.CreateServerImage(app, app_args, cmd_name=None)
Bases: ShowOne
-
IMAGE_API_VERSIONS = {'1': 'openstackclient.image.v1.image', '2': 'openstackclient.image.v2.image'}
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server_image.CreateServerImage (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
openstackclient.compute.v2.server_migration module
Compute v2 Server Migration action implementations
-
class openstackclient.compute.v2.server_migration.AbortMigration(app, app_args, cmd_name=None)
Bases: Command
Cancel an ongoing live migration.
This command requires --os-compute-api-version
2.24 or greater.
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server_migration.AbortMigration (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server_migration.ForceCompleteMigration(app, app_args, cmd_name=None)
Bases: Command
Force an ongoing live migration to complete.
This command requires --os-compute-api-version
2.22 or greater.
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server_migration.ForceCompleteMigration (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.server_migration.ListMigration(app, app_args, cmd_name=None)
Bases: Lister
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server_migration.ListMigration (WARNING)>
-
print_migrations(parsed_args, compute_client, migrations)
-
take_action(parsed_args)
Run command.
Return a tuple containing the column names and an iterable containing
the data to be listed.
-
class openstackclient.compute.v2.server_migration.ShowMigration(app, app_args, cmd_name=None)
Bases: ShowOne
Show an in-progress live migration for a given server.
Note that it is not possible to show cold migrations or completed
live-migrations. Use ‘openstack server migration list’ to get details for
these.
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server_migration.ShowMigration (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.
openstackclient.compute.v2.server_volume module
Compute v2 Server action implementations
-
class openstackclient.compute.v2.server_volume.ListServerVolume(app, app_args, cmd_name=None)
Bases: Lister
List all the volumes attached to a server.
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server_volume.ListServerVolume (WARNING)>
-
take_action(parsed_args)
Run command.
Return a tuple containing the column names and an iterable containing
the data to be listed.
-
class openstackclient.compute.v2.server_volume.UpdateServerVolume(app, app_args, cmd_name=None)
Bases: Command
Update a volume attachment on the server.
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.server_volume.UpdateServerVolume (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
openstackclient.compute.v2.service module
Service action implementations
-
class openstackclient.compute.v2.service.DeleteService(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.service.DeleteService (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
-
class openstackclient.compute.v2.service.ListService(app, app_args, cmd_name=None)
Bases: Lister
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.service.ListService (WARNING)>
-
take_action(parsed_args)
Run command.
Return a tuple containing the column names and an iterable containing
the data to be listed.
-
class openstackclient.compute.v2.service.SetService(app, app_args, cmd_name=None)
Bases: Command
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.service.SetService (WARNING)>
-
take_action(parsed_args)
Override to do something useful.
The returned value will be returned by the program.
openstackclient.compute.v2.usage module
Usage action implementations
-
class openstackclient.compute.v2.usage.CountColumn(value)
Bases: FormattableColumn
-
human_readable()
Return a basic human readable version of the data.
-
class openstackclient.compute.v2.usage.FloatColumn(value)
Bases: FormattableColumn
-
human_readable()
Return a basic human readable version of the data.
-
class openstackclient.compute.v2.usage.ListUsage(app, app_args, cmd_name=None)
Bases: Lister
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.usage.ListUsage (WARNING)>
-
take_action(parsed_args)
Run command.
Return a tuple containing the column names and an iterable containing
the data to be listed.
-
class openstackclient.compute.v2.usage.ProjectColumn(value, project_cache=None)
Bases: FormattableColumn
Formattable column for project column.
Unlike the parent FormattableColumn class, the initializer of the class
takes project_cache as the second argument.
osc_lib.utils.get_item_properties
instantiates FormattableColumn
objects with a single parameter, the column value, so you need to pass a
partially initialized class like functools.partial(ProjectColumn,
project_cache)
to use this.
-
human_readable()
Return a basic human readable version of the data.
-
class openstackclient.compute.v2.usage.ShowUsage(app, app_args, cmd_name=None)
Bases: ShowOne
-
get_parser(prog_name)
Return an argparse.ArgumentParser
.
-
log = <Logger openstackclient.compute.v2.usage.ShowUsage (WARNING)>
-
take_action(parsed_args)
Return a two-part tuple with a tuple of column names
and a tuple of values.