Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

write OpenStack automation scripts using Python API

Hi all,

i want to write some automation script using the Python API that described here using the python-novaclient package. i saw some example for python API scripts in this guide.

my question is, where to write this script (in devstack)? and where and how to run it? can you please also point me to appropriate guide?

thanks in advance, Alon?

write OpenStack automation scripts using Python API

Hi all,

i want to write some automation script using the Python API that described here using the python-novaclient package. i saw some example for python API scripts in this guide.

my question is, where to write this script (in devstack)? and where and how to run it? can you please also point me to appropriate guide?

the main purpose of the automation is to generate live migration at specific times and conditions, i will use this API method in order to do so:

live_migrate(server, host, block_migration, disk_over_commit)
Migrates a running instance to a new machine.
Parameters: •   server – instance id which comes from nova list.
•   host – destination host name.
•   block_migration – if True, do block_migration.
•   disk_over_commit – if True, Allow overcommit.

thanks in advance, Alon?