Package: vmpooler-client
The “vmpooler_client.py” script provides the ability to manage
vmpoolerresources in the vcloud. Currently the script supports grabbinga new VM for testing and handing a VM back to the pooler to bedestroyed.To get help on the command-line for the script use the command:vmpooler_client_app.py -hQuickstart# Create a token (only on first run)
$ ./vmpooler_client_app.py token create
Please provide LDAP credentials for the VM pooler

Username: bob.smith
Password:

Token: <token>

# List available templates
$ ./vmpooler_client_app.py vm list redhat
redhat-4-x86_64
redhat-5-i386
redhat-5-x86_64
redhat-6-i386
redhat-6-x86_64
redhat-7-x86_64

# Grab a VM
$ ./vmpooler_client_app.py vm get redhat-6-x86_64
Hostname: h2qbe7c29ix2w1r

# Login and do work
$ ssh root@h2qbe7c29ix2w1r

# Logout

# Give vm back to the pool
$ ./vmpooler_client_app.py vm destroy h2qbe7c29ix2w1rExamplesvmpooler_client_app.pyis separated into a few subcommands:vmpooler_client_app.py
    * vm
        * list
        * get
        * destroy
        * destroy_all
        * info
        * running
    * lifetime
        * get
        * extend
        * set
    * token
        * create
        * validate
        * revoke
    * config
        * get
        * set
        * list
        * unsetHelp is available for each subcommand by appending-hto the
command:vmpooler_client_app.py lifetime set -hList vmpooler templatesThis will list all the available templates.Usagevmpooler_client_app.py vm listFilter the list vmpooler templatesFilter available templates via a fuzzy matching pattern.Usagevmpooler_client_app.py vm list PATTERNExamplevmpooler_client_app.py vm list winGet a VM from the vmpoolerIt is required that you know what the template names are for thevmpooler.Usagevmpooler_client_app.py vm get TEMPLATE_NAMEExamplevmpooler_client_app.py vm get ubuntu-1404-x86_64List all of your running VMsThis gives you a concise list of what VMs you have runningUsagevmpooler_client_app.py vm runningExample Outputl2l7jdlpt6xlptq | Running: 4.27 hours | centos-6-i386
etcgjzxks2vtw9t | Running: 0.15 hours | centos-5-i386Hand a VM back to the vmpooler for destructionIt is required that you know what the hostname is for the VM you want
todestroy.Usagevmpooler_client_app.py vm destroy VM_NAMEExamplevmpooler_client_app.py vm destroy skj3k4hahdkHand all active VMs back to the vmpooler for destructionBe careful, this will destroy every active VM associate with your tokenUsagevmpooler_client_app.py vm destroy_allExample OutputDestroying etcgjzxks2vtw9t
Destroying l2l7jdlpt6xlptqGet the time to live for a VM in the vmpoolerUsagevmpooler_client_app.py lifetime get VM_NAMEExamplevmpooler_client_app.py lifetime get skj3k4hahdkExtend the time to live for a VM in the vmpoolerThis command will add a certain number of hours to the lifetime of a VMUsagevmpooler_client_app.py lifetime extend VM_NAME LIFETIMEExamplevmpooler_client_app.py lifetime extend skj3k4hahdk 2
> Lifetime extended to 10 hoursSet the total time to live for a VM in the vmpooler to a certain number of hoursThis command will overwrite the time to live for a VMUsagevmpooler_client_app.py lifetime set VM_NAME LIFETIMEExamplevmpooler_client_app.py lifetime set skj3k4hahdk 24Get information on a VM in the vmpoolerThis will work on running and destroyed VMs in the vmpooler.Usagevmpooler_client_app.py vm info VM_NAMEExamplevmpooler_client_app.py vm info skj3k4hahdkCreate an authorization token for use with the vmpoolerWARNING! Know what you’re doing before using this function!Usagevmpooler_client_app.py token createRevoke an authorization tokenWARNING! Know what you’re doing before using this function!Usagevmpooler_client_app.py token revoke TOKENExamplevmpooler_client_app.py token revoke sfn3h65earxah6ar9aal3oac2pfx9817Verify that an authorization token is validWARNING! Know what you’re doing before using this function!Usagevmpooler_client_app.py token validate TOKENExamplevmpooler_client_app.py token validate sfn3h65earxah6ar9aal3oac2pfx9817Read a config settingUsagevmpooler_client_app.py config get SETTING_NAMEExamplevmpooler_client_app.py config get usernameModify/create a config settingModify an existing setting or create add a new setting if it doesn’t
exist yet.Usagevmpooler_client_app.py config set SETTING_NAME VALUEExamplesvmpooler_client_app.py config set username bob.smith
vmpooler_client_app.py config set a_new_setting some_valueRemove a config settingUsagevmpooler_client_app.py config unset SETTING_NAMEExamplevmpooler_client_app.py config unset auth_tokenList all config settingsPrint all the settings in the config fileUsagevmpooler_client_app.py config list