/usr/lib/python2.6/site-packages/novaclient/v2
NameSizeModeActions
contrib/-0755rm
agents.py22400644editdlrm
agents.pyc27740644editdlrm
aggregates.py35000644editdlrm
aggregates.pyc47770644editdlrm
availability_zones.py15880644editdlrm
availability_zones.pyc17030644editdlrm
certs.py14100644editdlrm
certs.pyc16510644editdlrm
client.py98590644editdlrm
client.pyc86520644editdlrm
cloudpipe.py19060644editdlrm
cloudpipe.pyc24740644editdlrm
fixed_ips.py16830644editdlrm
fixed_ips.pyc20990644editdlrm
flavors.py68240644editdlrm
flavors.pyc76230644editdlrm
flavor_access.py26540644editdlrm
flavor_access.pyc32570644editdlrm
floating_ips.py17300644editdlrm
floating_ips.pyc22220644editdlrm
floating_ips_bulk.py21080644editdlrm
floating_ips_bulk.pyc22860644editdlrm
floating_ip_dns.py43780644editdlrm
floating_ip_dns.pyc62600644editdlrm
floating_ip_pools.py10640644editdlrm
floating_ip_pools.pyc12550644editdlrm
fping.py17500644editdlrm
fping.pyc20390644editdlrm
hosts.py20940644editdlrm
hosts.pyc32540644editdlrm
hypervisors.py28260644editdlrm
hypervisors.pyc40420644editdlrm
images.py31510644editdlrm
images.pyc41370644editdlrm
keypairs.py34970644editdlrm
keypairs.pyc39440644editdlrm
limits.py30920644editdlrm
limits.pyc43110644editdlrm
networks.py48150644editdlrm
networks.pyc58360644editdlrm
quotas.py22640644editdlrm
quotas.pyc26190644editdlrm
quota_classes.py15000644editdlrm
quota_classes.pyc17750644editdlrm
security_groups.py30000644editdlrm
security_groups.pyc41210644editdlrm
security_group_default_rules.py27410644editdlrm
security_group_default_rules.pyc33260644editdlrm
security_group_rules.py26810644editdlrm
security_group_rules.pyc29880644editdlrm
servers.py450640644editdlrm
servers.pyc502360644editdlrm
server_groups.py20600644editdlrm
server_groups.pyc28110644editdlrm
server_migrations.py29240644editdlrm
server_migrations.pyc33320644editdlrm
services.py33050644editdlrm
services.pyc40980644editdlrm
shell.py1486850644editdlrm
shell.pyc1490900644editdlrm
usage.py20190644editdlrm
usage.pyc23270644editdlrm
versions.py30320644editdlrm
versions.pyc26340644editdlrm
virtual_interfaces.py10390644editdlrm
virtual_interfaces.pyc12520644editdlrm
volumes.py77310644editdlrm
volumes.pyc80880644editdlrm
volume_snapshots.py44750644editdlrm
volume_snapshots.pyc47790644editdlrm
volume_types.py36980644editdlrm
volume_types.pyc39890644editdlrm
__init__.py6490644editdlrm
__init__.pyc2190644editdlrm
Edit: /usr/lib/python2.6/site-packages/novaclient/v2/shell.pyc (149090B)
=vVc?@sLddklZddkZddkZddkZddkZddkZddkZddkZddk Z ddk Z ddk l Z ddk l Z ddk lZddk lZddkZddklZddklZdd klZdd klZdd klZdd klZdd klZddklZddklZeieZ h dd6dd6dd6dd6dd6dd6dd6dd6d d!6d"d#6Z!d$Z"d%Z#d&Z$d'Z%d(Z&ei'd)d*dd+d,d-ed.ei'd/d*dd+d0d-ed1ei'd2d*gd!e#d3d4d+d5d-ed6ei'd7d*dd+d8d-ed9ei'd:d*dd+d;d-ed<ei'd=d*dd!e)d+d>d-ei*ei'd?d*dd!e)d+d>d-ed@ei'dAd*dd!e)d+d>d-edBei'dCd+d5d3d4d*gd-edDei'dEd+dFd3d4ddGd*gd-edHei'dId*ei+i,dJd+dKd-edLei'dMd-ei*ei'dNd+dOd-edPei'dQd*dd+dRd-edSei'dTd-ei*ei'dUd*dd+dVd-edWei'dXd-ei*ei'dYd*dd+dZd-ed[ei'd\d-ei*ei'd]d+d^d3d4d*gd-ed_ei'd`d3d4d-ei*ei'dad+dbd3d4d*gd-edcei'ddd+ded*dd-edfei'dgd+dhd3d4d*gd-ediei'djd3d4ddkd*gd+d5d-edlei'dmd+dnd3d4ddod*gd-edpei'dqd+drddsd*e-d-edtei'duddvd3dwd*e-d-edxei'dyddzd+drd*dd-ed{d|Z.d}Z/ei'd~d+dd-eddZ0ei'dd+dd-edei'dd+dd-eddZ1de2de-dZ3dZ4dZ5dZ6dZ7e-dZ8ei'dddd3dwd*e-d-edei'dddd3dwd*e-d-eddZ9ei'dd+d,d-eddZ:ei'dd+d,d-eddZ;ei'dNd+dOd-edei'dd+dd-edei'dd+dd-edei'dd+dd-edei'dgd+dd-edd*dei'dd+dd-edei'ddd+dd-edd*dei'dd+dd-edd*dei'dd+dd-edd!dd*e2dZ<ei'dd+d,d-edei'd3d+ddddgd-edei'dd+d5ddd3d4d*gd-eddZ=ei'd)d+d,d-edei'dd+dd-eddZ>ei'dd+d,d-edei'dd+dd-eddZ?ei'dd+d,d-edei'dd+dd-eddZ@ei'dd+dd-eddZAei'dd*dd+dd-eddZBei'dd+dd-eddZCei'dd+dd-eddZDei'dddd+dddd!e)ddd*dei'dddd+dddd!e)ddd*dei'dd+dd-eddZEei'dd+dd-edei'dd+dd-eddZFei'dd+dd-eddZGdZHei'dd+dd-edei'dddd+dd-edei'dddd-edei'dddd!e)d+dd-edei'dddd!e)d+dd-edei'dddd!e)d+dd-edei'dddd-edei'dddd-edei'dddd+dd-edei'ddd d+d d-ed ei'd dd d+dd-edei'dddd+dd-edei'dddd+dd-edei'dddd+dd-edei'dddd+dd-edei'dddd+dd-edei'd dd!d+d>d-ed"ei'd#dd$d!e)d-ed%ei'd&dd'd+dd-ed(ei'd)dd*d-ed+ei'd,dd-d+dd-ed.ei'd/dd0d-ed1ei'd2dd3d-ed4d5ZIei'd6dd7d+d8d-ed9d:ZJei'd;d+d0d-ed<ei'd3d+dddd=gd-ed>ei'dd+d5ddd3d4d*gd-ed?d@ZKdAZLdBZMdCZNei'd;d+d0d-ed<dDZOei'd;d+d0ddd-edEdFZPei'dGddHd+dId*dd-edJei'dKd-ei*ei'dLddMd+dNd*dd-edOei'dPddQd+dRd*dd-edSei'dTddNd+dUd*dd-edVei'dWddXd+dUd*dd-edYei'dZd-ei*ei'd[ddd+d\d*dd-ed]ei'd)ddd+d,d*dd-ed^ei'd/dd;d+d0d*dd-ed_ei'd`ddd+dad*dd-edbei'dcdddd+dddd!e)ddd*e)e iQei+i,dedfe2d-edgei'dhddd!e)ddd-ei*ei'dddd+diddd-edjei'dkddld+dmddd-ednei'doddpd3dwd*e-d-edqei'dd*dd+dd-edei'drddsd3dwd*e-d-edtei'duddvd+dwd-dxei'dyddzd+d{d*dd-d|ei'd6dd7d+d8d!e)d*dd-d}d~ZRei'dddd3ddeiSd*eiTd-edei'dd+dddd-edei'duddvd3dwd*e-d-eddZUei'dd+dd-edei'd;d+d0d-edei'dddd+dd*e-d-edei'dd-ei*ei'duddvd3dwd*e-d-edei'drddsd3dwd*e-d-edei'dd3dwd*e-d-edei'dTd+dOd*dd-edPei'dCd+d5d3d4d*gd-edDei'dEd+dFd3d4ddGd*gd-eddZVei'dd+dd-edei'dNd+dOd-eddZWei'dd+dd-edei'dd+d,d-edei'duddvd3dwd*e-d-eddZXei'dd+dd-eddZYei'dd+dd-eddZZei'dd+dd-edei'duddvd3dwd*e-d-eddZ[ei'dd+dd-eddZ\ei'dd+dd-eddZ]ei'dd+dddd-eddZ^ei'dd+dddd-eddZ_ei'dd+dd-eddZ`ei'dd+dd-eddZaei'dd+dd-eddZbei'dd+dd-eddZcei'dd+dd-edei'dd+dddd-edei'd/d+d0dd;d-eddZdei'dd+dd-eddZeei'dd+dd-eddZfei'dd+dd-eddZgei'dd+dd-eddZhei'dd+dd-eddZiei'dd+dd-eddZjei'dd+dd-eddZkei'dd+dd-eddZlei'dd+dd-edei'dNd+dOd-edei'dddd3dwd*e-d-edei'duddvd3dwd*e-d-eddZmei'dd+dd-edei'dNd+dOd-edei'dd+dd-edei'dd+dd-eddZnei'dd+dd-edei'd3d+dddd=gd-ed>ei'dd+d5ddd3d4d*gd-eddZoddZpei'drddsd3dwd*e-d-edei'dd+dd-eddZqei'dcd3dddd*dd-edei'dd+dddd-eddZrdZsdZtdZuei'dd+dd-edei'dd+dd-eddZvei'dd+dd-edei'dd+dd-eddZwdZxdZydZzdZ{dZ|dZ}dZ~ei'dcdddd+dddd!e)ddd*e)e iQei+i,dedfe2d-edgei'dhddd!e)ddd-ei*dZei'dd+dd-eddZei'dd+dd!e)d-edei'dd+dd*dd-edei'dd-ei*ei'dd+dd-edd*dei'dd+dd*dd-edei'dd-ei*ei'dd+dd*dd-edei'dd-ei*ei'dd+dd*dd-edei'dd-ei*ei'dUd+dVd-edd*ddZei'dd+dddd-eddZei'dd+dd-edei'dd+dd-edei'dd+dd*dddd-eddZei'dd+dd-edei'dd+dd-edei'dd+dd-eddZei'dd+dd-edei'dd+dd-eddZdZei'dd+dd-eddZei'd d+d d-ed ei'd d+d d-edd*e-ei'dd+dd*dd-edei'dd-ei*ei'dd+dd*dd-edei'dd-ei*dZei'dd+dd-eddZdZdZei'dNd+dOd-eddZei'dd+dd-eddZei'dd+dd-edei'dd+dd-eddZei'dd+dd-edei'dd+dd-eddZei'dd+dd-edei'dd+dd-ed d!Zei'dd+dd-edei'd"d*d#d-ed$d%Zei'dd+dd-edei'd&d+d'd-ed(ddd*dd)Zei'dd+dd-edd*Zd+Zei'dd+dd-edei'd,d+d-d*dd-ed.d/Zei'dd+dd-edei'dd+dd-edei'd0d+d1d*dd-ed2d3Zei'dd+dd-edei'dd+dd-edei'd0d+d1d*dd-ed2d4Zd5Zei'dd+dd-edei'dd+dd-edd6Zei'dd+dd-edei'dd+dd-edd7Zd8Zei'dd+dd-edei'd9d+d:d-ed;d<Zei'dd+dd-edei'd9d+d:d-ed;d=Zei'dd+dd-edd>Zei'd?d+d@d-edAddd*ddBZei'dd+dd-edCdDZdEZdFZei'd`ddd+dd*dd-edGdHZei'dId+dJd-edKei'dLdd?d+dMd*dd-edNei'dOd+dPd*dd-edQdRZei'dId+dJd-edSdTZdUZdVZdWZei'dXd+dYd-edZei'dLd+d[d-ed\d*dei'dTd+dOd-ed]d*dd^Zei'dMd+d[d-ed\ei'dNd+dOd-ed]ei'dXd+dYd-edZei'd_d+d`d-edad*dbdcZei'dXd+dYd-edZei'dNd+dOd-ed]ddZei'dXd+dYd-edZdeZei'dXd+dYd-edZei'dUd+dVd*dd-edfei'dXd-ei*dgZei'dXd+dYd-edZei'dhd+did-edjd*ddkZe2dlZdmZdnZei'd9d+d:d-edoei'dpd+dqd-edrei'dsd+dtd-eduei'dvd+dwd-edxei'dd+dyd-edzd{Zei'd9d+d:d-edoei'dpd+dqd-edrei'dsd+dtd-eduei'dvd+dwd-edxei'dd+dyd-edzd|Zei'dNd+dOd-ed}ei'd~d+dd-eddZei'd9d+d:d-edoei'dNd+dOd-ed}ei'd~d+dd-eddZei'd9d+d:d-edodZei'dcdddd+dddd!e)ddd*e)e iQei+i,dedfe2d-edgei'dhddd!e)ddd-ei*dZei'd9d+d:d-edodZei'd9d+d:d-edoei'dd+dd-edei'dpd+dqd-edrei'dsd+dtd-eduei'dvd+dwd-edxdZei'd9d+d:d-edoei'dd+dd-edei'dpd+dqd-edrei'dsd+dtd-eduei'dvd+dwd-edxdZeidddZeiddZei'dNd+dOd-edei'dd+dd*dd-edei'dd-ei*ei'dd+dd*dd-eddddZei'dNd+dOd-eddZeidddZeiddZdZdZei'dd+dd-eddZdZei'dddd+diddd-edjei'dddd3dwd*e-d-eddZdZdZdZei'dddd+diddd-edjei'dddd3dwd*e-d-eddZei'dd+dd-edd*dei'dd+dd-edd*ddZei'dd+dd-edd*dei'dd+dd-edd*dei'dd+dd*dd-eddZei'dd+dddd*dd-edei'dd+dddd*dd-eddZei'dd+dddd*dd-eddZei'dd+dd*dd-eddZei'dd+dd-edei'dd+dd-edei'dd+dd-edei'dd+dd-edei'dd+dd-edei'dd+dd*dd-eddZei'dd+dd-eddZei'dd+dd-edei'dd+dd-edei'dd+dd-edei'dd+dd-eddZdZdZei'dNd+dOd-edei'dd+dVd*dddd-eddZei'dd+dd-eddZei'dd+dd-edei'dNd+dOd-edei'dd+dVddd*dd-eddZei'dd+dd-edei'dd+d5ddd3d4d*gd-eddZei'dd+dd-edei'dd+dd-eddZei'dd+dd-edei'dd+dd-eddZei'dd+dd-eddZdZei'dd+dd-edei'dd+dd*dddd-edei'dd3dwddd*e-d-edei'dd3dwd-ei*ei'dd3dwddd*e-d-edei'dd3dwd-ei*dZei'dd+dddd-edei'dd3dddd*dddd-eddZei'dd+dd-eddZei'd`d+dad*dd-edei'dd+d d*dd-ed d Zei'dd+dad-edei'd d+d d-ed d Zei'dd+dad-edei'd d+d d-ed ei'dd+dd-eddZeidei'dd+dad-edei'd d+d d-ed ei'dddd-edd3dd*e2dZei'dd+dd-eddZeidddZeiddZei'dd+dd-ed d!Zei'dd+dd-ed d"Zei'dd+dd-ed d#Zei'dd+dad-edd$Zei'd%d+d&d*dd-ed'd(Zei'dd+dad-edei'd[d+d)d*dddd-ed*ei'd+d+d)d*ddd,d-ed-d.Zei'dd+dad-edei'd/d+ddd3dd0d#d1gd-ed2d3Zd4Zei'd5d+dad*dd-ed6d7Zei'd8d+dad-ed9d:Zei'dd+dd-ed;ei'd<dd=d+d>d*d?d-ed@dAZei'dd+dd-edBdCZdDZdEZdFZdGZdHZei'd<dd=d+d>d*dId-edJdKZei'dd+dd-edei'dLddd3dMd!e)d*dNd-edOei'dPddQd3dwd*e-d-ei*ei'dRddSd3dMd!ed*dTd-edUei'dVd+dd-edWd*dei'dXddYd3dwd*e-d-edZei'd[d+d\d-ed]d*d^ei'd_d`ddad-edbd*dcei'dddded-edfd*dcdgZdhdiddjdkdldmdndodpdqdrdsdtgZduZdvZei'dd+dd*dd-edwei'dkd+dxd*dd-edydzZei'dd+dd*dd-ed{d|Zei'dd+dd-ed}ei'dkd+dxd*dd-ed~ei'dd+dd!e)d*dd-edei'dd+dd!e)d*dd-edei'dd+dd!e)d*dd-edei'dd+dd!e)d*dd-edei'dd!e)d-ei*ei'dd+dd!e)d*dd-edei'dd+dd!e)d*dd-edei'dd!e)d-ei*ei'dd+dd!e)d*dd-edei'dd!e)d-ei*ei'dd+dd!e)d*dd-edei'dd!e)d-ei*ei'dd+dd!e)d*dd-edei'dd+dd!e)d*dd-edei'dYd+dZd!e)d*dd-edei'dd+dd!e)d*dd-edei'dd+dd!e)d*dd-edei'dd+dd!e)d*dd-edei'd ddd3dwd*dd-eddZei'dd+dde2d-edei'dkd+dxd-eddZei'dd+dd-eddZei'dd+dd-edei'dd+dd!e)d*dd-edei'dd+dd!e)d*dd-edei'dd+dd!e)d*dd-edei'dd+dd!e)d*dd-edei'dd!e)d-ei*ei'dd+dd!e)d*dd-edei'dd+dd!e)d*dd-edei'dd!e)d-ei*ei'dd+dd!e)d*dd-edei'dd!e)d-ei*ei'dd+dd!e)d*dd-edei'dd!e)d-ei*ei'dd+dd!e)d*dd-edei'dd+dd!e)d*dd-edei'dYd+dZd!e)d*dd-edei'dd+dd!e)d*dd-edei'dd+dd!e)d*dd-edei'dd+dd!e)d*dd-eddZei'dd+dd-edei'dd+dddd-edei'dddd+dd-edei'dddd3dwd*e-d-eddZdZei'dd+dd-eddZei'dd+dd-edei'dd+dd-edddei'dd+dd-edd*dddei'dd+dd-edd*ddddZei'dd+dd-edei'dd+dd-eddZdZeiddZdZ ei'dddd3dwd*e-d-eddZ dZ ei'dpd+dqd-edrei'dsd+dtd-eduei'dvd+dwd-edxei'dd+dyd-edzdZ ei'dpd+dqd-edrei'dsd+dtd-eduei'dvd+dwd-edxei'dd+dyd-edzdZ ei'dNd+dOd-edei'dd+dd*ei*ddd-edei'dd*gd3d4d-ei*dZei'dd+dddd-eddZei'dd+dd-eddZdZdS(i(tprint_functionN(t encodeutils(tstrutils(t timeutils(t uuidutils(t api_versions(tclient(t exceptions(t_(tcliutils(tutils(tavailability_zones(tquotas(tserverstuuidtidt source_typetsourcetdestination_typetdesttdisk_bustbust device_nametdevicet volume_sizetsizet guest_formattformatt boot_indext bootindext device_typettypetdelete_on_terminationtshutdowncCstd|dtidS(NsWARNING: Command %s is deprecated and will be removed after Nova 13.0.0 is released. Use python-cinderclient or openstackclient instead.tfile(tprinttsyststderr(t command_name((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytemit_volume_deprecation_warningCscCsYy&|idd\}}||fSWn,tj o d|}ti|nXdS(Nt=is$%r is not in the format of key=value(tsplitt ValueErrortargparsetArgumentTypeError(ttexttktvtmsg((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_key_value_pairingIs  cCs|ii}g}t|}x^|D]V}y:||it|iijo|i|nWq(tj oq(Xq(W|S(N(timagestlisttsett intersectiontmetadatatitemstappendtAttributeError(tcstwanted_propertiest image_listtimages_matchedtmatchtimg((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt _match_imageRs % c Csg}|io=h|id6dd6dd6dd6td6}|i|n|io=h|id6dd6dd6dd6td6}|i|nx|iD]}td |id D}h}x+ti|D]\}}||t |/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pys os t,tremovetlocaltblankicss"x|]}|idVqWdS(R(N(R)(RCR/((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pys s s Invalid ephemeral argument '%s'.RRRRtswap(t boot_volumetFalseR8RBt block_devicetdictR)tsixt iteritemstCLIENT_BDM2_KEYStgettTruet ephemeralR*RR+R,RH( targstimagetbdmtbdm_dictt device_spect spec_dicttkeytvaluetactiontephemeral_specteph_dictterr_msg((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_parse_block_device_mapping_v2_sX         #   c'(Cs*|iot||i}nd-}| o5|io+t||i}|o|d}qcn|iptitdnd}d}|i d-j oV|i d-joF|i d-jo6|i djotitdn|i }nJ|i d-j o9|i d-j p|i d-j otitdn|i d-j o<|i djotitdn|i }|}n|i d-j o6|i djotitdn|i }n|i d-j o<|i d-j o,|i |i jotitdnt ||i}t d |iD}h}x|iD]} y,| id d\} } t| || = 1s)Don't mix num-instances and max/min-countsmin_count should be >= 1smax_count should be >= 1s min_count should be <= max_countcss%x|]}|iddVqWdS(R(iN(R)(RCR/((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pys s R(sCan't open '%(src)s': %(exc)stsrctexcs[Invalid file argument '%s'. File arguments must be of the form '--file 's#Can't open '%(user_data)s': %(exc)st user_dataRDsyou need to specify at least one source ID (Image, Snapshot, or Volume), a block device mapping or provide a set of properties to match against an imagesyou can't mix old block devices (--block-device-mapping) with the new ones (--block-device, --boot-volume, --snapshot, --ephemeral, --swap)sInvalid nic argument '%s'. Nic arguments must be of the form --nic , with at minimum net-id or port-id (but not both) specified.tsnet-ids v4-fixed-ips v6-fixed-ipsport-idttruet1tfalset0tnonetmetatfilestkey_namet min_countt max_counttuserdatatavailability_zonetsecurity_groupstblock_device_mappingtblock_device_mapping_v2tnicstscheduler_hintst config_drivet admin_passN(strueRe(sfalseRgRcsnone(-RTt _find_imagetNonet image_withR@tflavorRt CommandErrorRt num_instancesRlRmt _find_flavorRLRiRjR)topentIOErrorR*RkRbRoRpRqR_tlenR3tfiltertboolRIRBRsR8Rtt partitiont isinstanceRMt string_typestnametstrRutlowerRQRv('R:RSRTR2RlRmRzRiRjtftdstR`teRkRnRoRpRqRURtmappingRrt n_boot_argsthave_bdmRstnic_strR^tnic_infotkv_strR.R/thintsthintRYt_sepRZt boot_argsRut boot_kwargs((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_boots                ! "    !       s--flavortdefaulttmetavarsthelps.Name or ID of flavor (see 'nova flavor-list').s--imagess-Name or ID of image (see 'nova image-list'). s --image-withR[R8s s1Image metadata property (see 'nova image-show'). s --boot-volumes sVolume ID to boot from.s --snapshots s0Snapshot ID to boot from (will create a volume).s--num-instancesss --min-counts2Boot at least servers (limited by quota).s --max-counts/Boot up to servers (limited by quota).s--metasoRecord arbitrary key/value metadata to /meta_data.json on the metadata server. Can be specified multiple times.s--filesRjsyStore arbitrary files from locally to on the new server. Limited by the injected_files quota value.s --key-nametNOVACLIENT_DEFAULT_KEY_NAMEs s[Key name of keypair that should be created earlier with the command keypair-add.s --key_nameRssName for the new server.s --user-datas s<user data file to pass to be exposed by the metadata server.s --user_datas--availability-zoness+The availability zone for server placement.s--availability_zones--security-groupsss-Comma separated list of security group names.s--security_groupss--block-device-mappingss[Block device mapping in the format =:::.s--block_device_mappings--block-deviceskey1=value1[,key2=value2...]sBlock device mapping with the keys: id=UUID (image_id, snapshot_id or volume_id only if using source image, snapshot or volume) source=source type (image, snapshot, volume or blank), dest=destination type of the block device (volume or local), bus=device's bus (e.g. uml, lxc, virtio, ...; if omitted, hypervisor driver chooses a suitable default, honoured only if device type is supplied) type=device type (e.g. disk, cdrom, ...; defaults to 'disk') device=name of the device (e.g. vda, xda, ...; if omitted, hypervisor driver chooses suitable device depending on selected bus), size=size of the block device in MB(for swap) and in GB(for other formats) (if omitted, hypervisor driver calculates size), format=device will be formatted (e.g. swap, ntfs, ...; optional), bootindex=integer used for ordering the boot disks (for image backed instances it is equal to 0, for others need to be specified) and shutdown=shutdown behaviour (either preserve or remove, for local destination set to remove).s--swaps s>Create and attach a local swap block device of MB.s --ephemeralssize=[,format=]sXCreate and attach a local ephemeral block device of GB and format it to .s--hintRts?Send arbitrary key/value pairs to the scheduler for custom use.s--nicsKRsslCreate a NIC on the server. Specify option multiple times to create multiple NICs. net-id: attach NIC to network with this UUID (either port-id or net-id must be provided), v4-fixed-ip: IPv4 fixed address for NIC (optional), v6-fixed-ip: IPv6 fixed address for NIC (optional), port-id: attach NIC to port with this UUID (either port-id or net-id must be provided).s--config-drivesRusEnable config drive.s--polltpollt store_trues7Report the new server boot progress until it completes.s --admin-passRvs Admin password for the instance.cCst||\}}tit|}|i||ii||}t||||io#t |ii |i ddgndS(sBoot a new server.tbuildingtactiveN( RR t!get_resource_manager_extra_kwargstdo_boottupdateR tcreatet _print_serverRt_poll_for_statusRPR(R:RSRRtextra_boot_kwargstserver((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRIs  cCs5|ii}ddddg}ti||dS(s(Print a list of all cloudpipe instances.s Project Ids Public IPs Public Ports Internal IPN(t cloudpipeR3R t print_list(R:t_argst cloudpipestcolumns((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_cloudpipe_liststprojects s0UUID of the project to create the cloudpipe for.cCs|ii|idS(s2Create a cloudpipe instance for the given project.N(RRR(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_cloudpipe_createstaddresss sNew IP Address.tportss New Port.cCs|ii|i|idS(s/Update the VPN IP/port of a cloudpipe instance.N(RRRR(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_cloudpipe_configuresitstatusc sgfd}|p tnx<to4||} t| |} | o| i} nt| dd pd} | |jo*|p|dttdnPn| djo9|pttdnti| idnG| d jo9|pttd nti | idn|p|| nt i |q'Wd S( sRBlock while an action is being performed, periodically printing progress. csdo#tdtdd|}ntdtd}tii|tiidS(Ns- Server %(action)s... %(progress)s%% completeR[tprogresss Server %(action)s...(RRLR$tstdouttwritetflush(RR0(t show_progressR[(s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytprint_progress,s  Riids Finishedterrors Error %s servertmessagetdeleteds Deleted %s serverN( R#RQtgetattrRRxRRtInstanceInErrorStatetfaulttInstanceInDeletedStatettimetsleep( tpoll_fntobj_idR[tfinal_ok_statest poll_periodRt status_fieldtsilentRtobjRR((RR[s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR&s4       cCspxi|D]a}|ii}xI|D]A\}}||jo(||jot|||i|q#q#WqWdS(N(t__dict__tkeystsetattrt_info(t collectiontconverttitemRtfrom_keytto_key((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_translate_keysVs c Csddddddddg}x|D]}y!t|d|t|dWn#tj ot|dd nXyt|d Wq%tj ot|d d q%Xq%WdS( NtNOSTATEtRunningRctPausedtShutdowntCrashedt Suspendedt power_statesN/At task_state(RRR9(Rt power_statesR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_translate_extended_states^s&  cCst|dgdS(Ntramt memory_mb(sramR(R(R((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_translate_flavor_keysvscCs,y|iSWntij odSXdS(NsN/A(tget_keysRtNotFound(Rz((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_print_flavor_extra_specszsc Csmt|ddddddddd g }|ohtd 6}|id nh}ti|||dS( NtIDtNamet Memory_MBtDiskt EphemeraltSwaptVCPUst RXTX_Factort Is_Publict extra_specs(RRR8R R(tflavorstshow_extra_specstheaderst formatters((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_print_flavor_lists   s --extra-specsRsGet extra-specs of each flavor.s--alltalls!Display all flavors (Admin only).cCsF|io|iidd}n|ii}t||idS(s7Print a list of available 'flavors' (sizes of servers).t is_publicN(RRR3RxRR(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_flavor_lists Rzs#Name or ID of the flavor to delete.cCs3t||i}|ii|t|gdS(sDelete a specific flavorN(R}RzRtdeleteR(R:RStflavorid((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_flavor_deletessName or ID of flavor.cCs t||i}t|dS(s$Show details about the given flavor.N(R}Rzt _print_flavor(R:RSRz((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_flavor_showssName of the new flavor.sseUnique ID (integer or UUID) for the new flavor. If specifying 'auto', a UUID will be generated as ID.RssMemory size in MB.tdiskssDisk size in GB.s s'Ephemeral space size in GB (default 0).itvcpusssNumber of vcpusss"Swap space size in MB (default 0).s --rxtx-factorssRX/TX factor (default 1).g?s --is-publics s4Make flavor accessible to the public (default true).cCsti|tS((Rtbool_from_stringRQ(R/((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytsc CsV|ii|i|i|i|i|i|i|i|i |i }t |gdS(sCreate a new flavor.N( RRRRRRRRRRHt rxtx_factorRR(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_flavor_creates,' stchoicesR4tunsetsActions: 'set' or 'unset'.R6tnargst+s:Extra_specs to set/unset (only key is necessary on unset).cCsjt||i}t|}|idjo|i|n(|idjo|i|indS(s%Set or unset extra_spec for a flavor.R4RN(R}Rzt_extract_metadataR[tset_keyst unset_keysR(R:RSRztkeypair((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_flavor_keys  s$Filter results by flavor name or ID.s--tenants sFilter results by tenant ID.cCs|io#|iotitdn|ioFt||i}|iotitdnh|d6}n4|ioh|id6}ntitdy|ii|}Wn.t j o"}tidt |nXddg}t i ||d S( s0Print access information about the given flavor.s7Unable to filter results by both --flavor and --tenant.s1Failed to get access list for public flavor type.Rzttenants<Unable to get all access lists. Specify --flavor or --tenants%st Flavor_IDt Tenant_IDN( RzR RR{RR}Rt flavor_accessR3tNotImplementedErrorRR R(R:RSRztkwargst access_listRR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_flavor_access_lists     s5Flavor name or ID to add access for the given tenant.R s#Tenant ID to add flavor access for.cCsJt||i}|ii||i}ddg}ti||dS(s'Add flavor access for the given tenant.R R N(R}RzR tadd_tenant_accessR R R(R:RSRzRR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_flavor_access_add1s  s8Flavor name or ID to remove access for the given tenant.s&Tenant ID to remove flavor access for.cCsJt||i}|ii||i}ddg}ti||dS(s*Remove flavor access for the given tenant.R R N(R}RzR tremove_tenant_accessR R R(R:RSRzRR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_flavor_access_remove@s  t project_idsThe ID of the project.c Cs|ii}g}|D]-}t|dd|ijo ||qq~}hdd6}|ii|}g}|D]$}|i|ijo ||qzqz~}x|D]}|ii|qWx|D]}|ii|qWdS(s>Delete networks and security groups associated with a project.RRcit all_tenantsN(tnetworksR3RRRpt tenant_idt disassociateR( R:RSt networks_listt_[1]tnetworkt search_optstgroupst_[2]tgroup((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_scrubOs0 's--fieldsssbComma-separated list of fields to display. Use the show command to see which fields are available.c Cs|ii}dddg}h}g}|ioPxM|iidD]5}ti|h\}}|i||||/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_network_listas   Rs sUUID or label of network.cCs,ti|i|i}ti|idS(s%Show details about the given network.N(R t find_resourceRRt print_dictR(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_network_showxscCs&ti|i|i}|idS(sDelete network by label or id.N(R R-RRR(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_network_deletess --host-onlyt host_onlys<0|1>t?tconstis--project-onlyt project_onlysUUID of network.cCsk|io|ii|ittnA|io|ii|ittn|ii|ittdS(s8Disassociate host and/or project from the given network.N(R1RRRRQRJR4(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_network_disassociates   thostss Name of hostcCs|ii|i|idS(sAssociate host with network.N(Rtassociate_hostRR6(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_network_associate_hosts cCs|ii|idS(sAssociate project with network.N(Rtassociate_projectR(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_network_associate_projectscCsddddddddd d d d d ddddddddg}h}xE|iiD]4\}}||jo|dj o|||/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_filter_network_create_optionss   R;ssLabel for networks--fixed-range-v4R<s sIPv4 subnet (ex: 10.0.0.0/8)s--fixed-range-v6R?sIPv6 subnet (ex: fe80::/64s--vlanRIs s*The vlan ID to be assigned to the project.s --vlan-startR=s s`First vlan ID to be assigned to the project. Subsequent vlan IDs will be assigned incrementally.s--vpnR>s s vpn starts --gatewayR@s --gateway-v6RAs IPv6 gateways--bridgeRBss2VIFs on this network are connected to this bridge.s--bridge-interfaceRCss*The bridge is connected to this interface.s --multi-hostRDs <'T'|'F'>s Multi hosts--dns1REs s First DNS.s--dns2RFs Second DNS.s--uuidss Network UUID.s --fixed-cidrRGs-IPv4 subnet for fixed IPs (ex: 10.20.0.0/16).s --project-ids s Project ID.s --priorityRHsNetwork interface priority.s--mtuRJsMTU for network.s --enable-dhcpt enable_dhcps Enable DHCP.s --dhcp-serverRKs1DHCP-server address (defaults to gateway address)s--share-addresst share_addresss Share addresss--allowed-startRLs)Start of allowed addresses for instances.s --allowed-endRMs'End of allowed addresses for instances.cCs |ip|iptitdnt|}|idj o0t|idjpt i |i|d/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_network_creates r s--limittlimitss'Number of images to return per request.cCs]|i}|iid|}d}h|d6}ti|ddddg|ddd S( s.Print a list of available images to boot from.RTcSs0y|idSWnttfj odSXdS(NRRc(RR9tKeyError(RT((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytparse_server_name]stServerRRtStatust sortby_indexiN(RTR2R3R R(R:RRTR<RVtfmts((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_image_listSs    RTsName or ID of image.RsActions: 'set' or 'delete'.sCMetadata to add/update or delete (only key is necessary on delete).cCsvt||i}t|}|idjo|ii||n.|idjo|ii||indS(s#Set or Delete metadata on an image.R4RN(RwRTRR[R2tset_metat delete_metaR(R:RSRTR6((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_image_metahs  cCsjh}x]|idD]N}|iddjo|idd\}}n |}d}|||/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRsc Cs|ii}|id|idd}y|d|d/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt _print_images    cCsG|ii}|id|iht|d6ti|dS(NRaR(RRbRcRRR R.(RzRe((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRs cCs t||i}t|dS(s#Show details about the given image.N(RwRTRg(R:RSRT((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_image_showssName or ID of image(s).cCsixb|iD]W}yt||iWq tj o+}ttdh|d6|d6q Xq WdS(sDelete specified image(s).s(Delete for image %(image)s failed: %(e)sRTRN(RTRwRt ExceptionR#R(R:RSRTR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_image_deletes  s--reservation-idtreservation_idss.Only return servers that match reservation-id.s--reservation_ids--iptips s3Search with regular expression match by IP address.s--ip6tip6s s5Search with regular expression match by IPv6 address.s--names s-Search with regular expression match by name.s--instance-namet instance_names4Search with regular expression match by server name.s--instance_names--statusssSearch by server status.sSearch by flavor name or ID.sSearch by image name or ID.s--hosts sCSearch servers by hostname to which they are assigned (Admin only).s --all-tenantsRt ALL_TENANTSRfs2Display information from all tenants (Admin only).s --all_tenantsss4Display information from single tenant (Admin only).s--usertuserss2Display information from single user (Admin only).s --deletedRs*Only display deleted servers (Admin only).s --minimaltminimalsGet only UUID and name.s--sorttsorts[:]sComma-separated list of sort keys and directions in the form of [:]. The direction defaults to descending if not specified.s--markertmarkerssSThe last server UUID of the previous page; displays list of servers after "marker".sMaximum number of servers to display. If limit == -1, all servers will be displayed. If limit is bigger than 'osapi_max_limit' option of Nova API, limit 'osapi_max_limit' will be used instead.cCs;d-}d-}|iot||ii}n|iot||ii}n|ip |io d|_nh |id6|i d6|i d6|i d6|i d6|d6|d6|i d 6|id 6|id 6|id 6|id 6|id6}hdd6tid6}h}g}|ioPxM|iidD]5}ti||\} } |i| | || /tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRisRpRDRt:tdesctascsUnknown sort direction: %stdetailedRt sort_keyst sort_dirsRsRTsOS-EXT-SRV-ATTR:hostsOS-EXT-STS:task_stateRsOS-EXT-SRV-ATTR:instance_namesOS-EXT-STS:power_stateRthostIdthost_idRRXs Task States Power StatetNetworksis Tenant IDRYN(Rwsdesc(sOS-EXT-SRV-ATTR:hostshost(sOS-EXT-STS:task_states task_state(sOS-EXT-SRV-ATTR:instance_names instance_name(sOS-EXT-STS:power_states power_state(R{R|(&RxRTRwRRzR}R RpRRkRlRmRRR6RRnR t_format_security_groupsR%R)R&R8RqRrRRR{RR R3RsRTRRtinsertt_format_servers_list_networksR(R:RStimageidRRtfiltersRR(R)R*R+tid_colRxRyRzRrtsort_keyRtsort_dirR RRRY((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_lists                                      s--hardt reboot_typet store_consts.Perform a hard reboot (instead of a soft one).RssName or ID of server(s).sPoll until reboot is complete.c sg}iD]}|t|q~}tifd|tdtdio/tifd|tdtdndS(sReboot a server.cs|iiS((trebootR(ts(RS(s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRss.Request to reboot server %s has been accepted.s)Unable to reboot the specified server(s).cs%tii|iddgdtS(t rebootingRR(RR RPRRJ(R(R:(s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRssWait for server %s reboot.s$Wait for specified server(s) failed.N(Rt _find_serverR tdo_action_on_manyRR(R:RSRRR ((RSR:s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_reboots-      sName or ID of server.sName or ID of new image.s--rebuild-passwordtrebuild_passwordss6Set the provided admin password on the rebuilt server.s--rebuild_passwords6Report the server rebuild progress until it completes.s0Skips flavor/image lookups when showing servers.s--preserve-ephemerals<Preserve the default ephemeral storage partition on rebuild.skStore arbitrary files from locally to on the new server. You may store up to 5 files.c Cst||i}t||i}|itj o |i}nd}tit |}|i |d<|i |d/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pys s RiR(itrNsCan't open '%(src)s': %(exc)sR`Ras[Invalid file argument '%s'. File arguments must be of the form '--file 'Rjt rebuildingR( RRRwRTRRJRxR Rt do_rebuildRRRLRiRjR)R~t__exit__t __enter__treadRRR{RR*trebuildRRRR RPR(R:RSRRTt _passwordRRiRjRRR`RRR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRs82     &  s Name (old name) or ID of server.sNew name for the server.cCs#t||iid|idS(sRename a server.RN(RRRR(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_rename'ssName or ID of new flavor.s5Report the server resize progress until it completes.cCszt||i}t||i}tit|}|i|||io&t |i i |i dddgndS(sResize a server.tresizingRt verify_resizeN( RRR}RzR Rt do_resizetresizeRRR RPR(R:RSRRzR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR0s  cCst||iidS(sConfirm a previous resize.N(RRtconfirm_resize(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_resize_confirmFscCst||iidS(s9Revert a previous resize (and return to the previous VM).N(RRt revert_resize(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_resize_revertLss8Report the server migration progress until it completes.cCsPt||i}|i|io&t|ii|idddgndS(sAMigrate a server. The new host will be selected by the scheduler.t migratingRRN(RRtmigrateRRR RPR(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_migrateRs   cCst||iidS(sPause a server.N(RRtpause(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_pausecscCst||iidS(sUnpause a server.N(RRtunpause(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_unpauseiscs2tifd|itdtddS(sStop the server(s).cst|iS((Rtstop(R(R:(s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRvss,Request to stop server %s has been accepted.s'Unable to stop the specified server(s).N(R RRR(R:RS((R:s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_stopos   cs2tifd|itdtddS(sStart the server(s).cst|iS((Rtstart(R(R:(s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRss-Request to start server %s has been accepted.s(Unable to start the specified server(s).N(R RRR(R:RS((R:s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_start|s   cCst||iidS(siLock a server. A normal (non-admin) user will not be able to execute actions on a locked server. N(RRtlock(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_lockscCst||iidS(sUnlock a server.N(RRtunlock(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_unlockscCst||iidS(sSuspend a server.N(RRtsuspend(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_suspendscCst||iidS(sResume a server.N(RRtresume(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_resumess --passwords tpasswords7The admin password to be set in the rescue environment.sThe image to rescue with.cCsoh}|iot||i|d/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_rescues   cCst||iidS(s/Restart the server from normal boot disk again.N(RRtunrescue(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_unrescuescCst||iidS(sShelve a server.N(RRtshelve(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_shelvescCst||iidS(s.Remove a shelved server from the compute node.N(RRtshelve_offload(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_shelve_offloadscCst||iidS(sUnshelve a server.N(RRtunshelve(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_unshelvescCs9t||i}ti|ii|ddddS(sRetrieve server diagnostics.itwrapiPN(RRR R.R t diagnostics(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_diagnosticsssaName or ID of a server for which the network cache should be refreshed from neutron (Admin only).cCs:t||i}|iih|id6dd6gdS(s#Refresh server network information.t server_uuidsnetwork-changedRN(RRtserver_external_eventsRR(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_refresh_networkscCst||dS(s%DEPRECATED, use set-password instead.N(tdo_set_password(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_root_passwordscCsgt||i}tid}tid}||jotitdn|i|dS(s1 Change the admin password for a server. sNew password: sAgain: sPasswords do not match.N(RRtgetpassRR{Rtchange_password(R:RSRtp1tp2((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRs  sName of snapshot.s--showtshowsPrint image info.sGReport the snapshot progress and poll until image creation is complete.c Cst||i}|ii||i}|iokt|ii|ddgd}t ||o5t|ii|i ddgd|dt dt qn|iot|ii|ndS( s<Create a new image by taking a snapshot of a running server.t snapshottingRsOS-EXT-STS:task_statetimage_snapshotRRRN(RRR t create_imageRRRR2RPthasattrRRxRJRQRRg(R:RSRt image_uuidttask_state_field((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_image_creates   sName of the backup image.t backup_types s*The backup type, like "daily" or "weekly".trotations s;Int parameter representing how many backups to keep around.cCs,t||ii|i|i|idS(s5Backup a server by creating a 'backup' type snapshot.N(RRtbackupRRR(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_backup#s s<Metadata to set or delete (only key is necessary on delete).cCst||i}t|}|idjo|ii||n:|idjo)|ii|t|idt ndS(s#Set or Delete metadata on a server.R4RtreverseN( RRRR[R R\R]tsortedRRQ(R:RSRR6((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_meta3s  c Cs|pt||i}nt|dt}|i}|ii}x1|iD]#\}}di||d|/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pys ns RTsImage not founds/Attempt to boot from volume - no image suppliedRat addresses(RRRRJRRRbR7tjoinRPR}RRiRRR4RwRcRxR R.( R:RSRRqRRet network_labelt address_listRzt flavor_idRTtimage_id((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRNsD   +#cCst||dS(s$Show details about the given server.N(R(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_shows s8Delete server(s) in another tenant by name (Admin only).csEh|id6tifd|itdtddS(s5Immediately shut down and delete specified server(s).Rcst|iS((RR(R(R:t find_args(s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRss.Request to delete server %s has been accepted.s)Unable to delete the specified server(s).N(RR RRR(R:RS((RR:s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_deletes  cKsti|i||S(sGet a server by name or ID.(R R-R (R:RR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRscCsti|i|S(sGet an image by name or ID.(R R-R2(R:RT((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRwscCsJyti|i|ddSWn&tij o|iid|SXdS(s&Get a flavor by name, ID, or RAM size.RRN(R R-RRxRRR_(R:Rz((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR}st network_ids s Network ID.cCs&t||i}|i|idS(s*Add new IP address on a network to server.N(RRt add_fixed_ipR(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_add_fixed_ipss
s IP Address.cCs&t||i}|i|idS(s#Remove an IP address from a server.N(RRtremove_fixed_ipR(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_remove_fixed_ipscCsti|i|S(sGet a volume by name or ID.(R R-tvolumes(R:RA((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt _find_volumescCsti|i|S(s$Get a volume snapshot by name or ID.(R R-tvolume_snapshots(R:RB((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_find_volume_snapshotscCsti|idS(N(R R.R(RA((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt _print_volumescCsti|idS(N(R R.R(RB((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_print_volume_snapshotscCst|ddgdS(Nt displayNamet display_namet volumeTypet volume_type(Rs display_name(Rs volume_type(R(R((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_translate_volume_keysscCst|ddgdS(NRRtvolumeIdt volume_id(s displayNames display_name(Rs volume_id(R(R((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_translate_volume_snapshot_keysscCst|ddgdS(NtzoneNameRt zoneStateR(szoneNamesname(s zoneStatesstatus(R(R((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt!_translate_availability_zone_keyssc Cstdh|id6}|iid|}t|x]|D]U}g}|iD]}||idqT~}t|ddit t |q@Wt i |ddd d d d gd S(s!DEPRECATED: List all the volumes.s volume-listRRt server_idt attached_toRDRRXs Display NametSizes Volume Types Attached toN( R'RRR3Rt attachmentsRPRRtmapRR R(R:RSRRtvolRRR ((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_volume_lists  -&RAssName or ID of the volume.cCs*tdt||i}t|dS(s(DEPRECATED: Show details about a volume.s volume-showN(R'RRAR(R:RSRA((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_volume_show s ssSize of volume in GBs --snapshot-ids s>Optional snapshot id to create the volume from. (Default=None)s --snapshot_ids --image-ids s;Optional image id to create the volume from. (Default=None)s--display-namess$Optional volume name. (Default=None)s--display_names--display-descriptionss+Optional volume description. (Default=None)s--display_descriptions --volume-types s$Optional volume type. (Default=None)s --volume_types5Optional Availability Zone for volume. (Default=None)c CsTtd|ii|i|i|i|i|i|id|i }t |dS(sDEPRECATED: Add a new volume.s volume-createtimageRefN( R'RRRt snapshot_idRtdisplay_descriptionRRoRR(R:RSRA((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_volume_creates0   s&Name or ID of the volume(s) to delete.cCsstdxb|iD]W}yt||iWqtj o+}ttdh|d6|d6qXqWdS(sDEPRECATED: Remove volume(s).s volume-deletes*Delete for volume %(volume)s failed: %(e)sRARN(R'RARRRiR#R(R:RSRAR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_volume_deletePs   sID of the volume to attach.ssJName of the device e.g. /dev/vdb. Use "auto" for autoassign (if supported)cCsX|idjo d|_n|iit||ii|i|i}t|dS(sAttach a volume to a server.tautoN( RRxRtcreate_server_volumeRRRRAR(R:RSRA((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_volume_attach_s   t attachment_ids sAttachment ID of the volume.t new_volumecCs/|iit||ii|i|idS(sUpdate volume attachment.N(Rtupdate_server_volumeRRRR R (R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_volume_updatevssID of the volume to detach.cCs)|iit||ii|idS(sDetach a volume from a server.N(Rtdelete_server_volumeRRRR (R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_volume_detachs cCsFtd|ii}t|ti|dddddgdS(s#DEPRECATED: List all the snapshots.svolume-snapshot-listRs Volume IDRXs Display NameRN(R'RR3RR R(R:Rt snapshots((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_volume_snapshot_lists   RBs sName or ID of the snapshot.cCs*tdt||i}t|dS(s*DEPRECATED: Show details about a snapshot.svolume-snapshot-showN(R'RRBR(R:RSRB((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_volume_snapshot_shows Rs sID of the volume to snapshots--forces shOptional flag to indicate whether to snapshot a volume even if its attached to a server. (Default=False)s&Optional snapshot name. (Default=None)s-Optional snapshot description. (Default=None)cCs?td|ii|i|i|i|i}t|dS(sDEPRECATED: Add a new snapshot.svolume-snapshot-createN(R'RRRtforceRRR(R:RSRB((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_volume_snapshot_creates   s%Name or ID of the snapshot to delete.cCs*tdt||i}|idS(sDEPRECATED: Remove a snapshot.svolume-snapshot-deleteN(R'RRBR(R:RSRB((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_volume_snapshot_deletes cCsti|ddgdS(NRR(R R(tvtypes((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_print_volume_type_listscCs'td|ii}t|dS(s5DEPRECATED: Print a list of available 'volume types'.svolume-type-listN(R't volume_typesR3R(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_volume_type_lists sName of the new volume typecCs0td|ii|i}t|gdS(s%DEPRECATED: Create a new volume type.svolume-type-createN(R'RRRR(R:RStvtype((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_volume_type_creates s'Unique ID of the volume type to delete.cCs!td|ii|idS(s*DEPRECATED: Delete a specific volume type.svolume-type-deleteN(R'RRR(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_volume_type_deletes t console_typess*Type of vnc console ("novnc" or "xvpvnc").cCsat||i}|i|i}dtfdY}ti||dgddgdS(sGet a vnc console to a server.t VNCConsolecBseZdZRS(cSs|d|_|d|_dS(NRturl(RR(tselft console_dict((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt__init__ s (t__name__t __module__R"(((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR stconsoletTypetUrlN(RRtget_vnc_consoleRtobjectR R(R:RSRtdataR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_get_vnc_consoless&Type of spice console ("spice-html5").cCsat||i}|i|i}dtfdY}ti||dgddgdS(s Get a spice console to a server.t SPICEConsolecBseZdZRS(cSs|d|_|d|_dS(NRR(RR(R R!((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR" s (R#R$R"(((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR, sR%R&R'N(RRtget_spice_consoleRR)R R(R:RSRR*R,((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_get_spice_console ss"Type of rdp console ("rdp-html5").cCsat||i}|i|i}dtfdY}ti||dgddgdS(sGet a rdp console to a server.t RDPConsolecBseZdZRS(cSs|d|_|d|_dS(NRR(RR(R R!((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR") s (R#R$R"(((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR/( sR%R&R'N(RRtget_rdp_consoleRR)R R(R:RSRR*R/((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_get_rdp_console ss--console_typetserials)Type of serial console, default="serial".cCs|id jotitdnt||i}|i|i}dtfdY}ti ||dgddgdS( s!Get a serial console to a server.R2sIInvalid parameter value for 'console_type', currently supported 'serial'.t SerialConsolecBseZdZRS(cSs|d|_|d|_dS(NRR(RR(R R!((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR"? s (R#R$R"(((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR3> sR%R&R'N(sserial( RRR{RRRtget_serial_consoleR)R R(R:RSRR*R3((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_get_serial_console0 st private_keys sPrivate key (used locally to decrypt password) (Optional). When specified, the command displays the clear (decrypted) VM password. When not specified, the ciphered VM password is displayed.cCs2t||i}|i|i}t|dS(s$Get the admin password for a server.N(RRt get_passwordR6R#(R:RSRR*((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_get_passwordF s cCs t||i}|idS(s&Clear the admin password for a server.N(RRtclear_password(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_clear_passwordW scCs9dg}t||ti|dddddgdS( Nt instance_idRtIdtIPs Server IdsFixed IPtPool(R;s server_id(RR R(t floating_ipsR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_print_floating_ip_list^ s   s--lengthssLength in lines to tail.cCs5t||i}|id|i}t|dS(s#Get console log output of a server.tlengthN(RRtget_console_outputRAR#(R:RSRR*((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_console_logf ss--fixed-addressss#Fixed IP Address to associate with.cCst||dS(s.DEPRECATED, use floating-ip-associate instead.N(t_associate_floating_ip(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_add_floating_ips s cCst||dS(s,Associate a floating IP address to a server.N(RD(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_floating_ip_associate s cCs,t||i}|i|i|idS(N(RRtadd_floating_ipRt fixed_address(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRD scCst||dS(s1DEPRECATED, use floating-ip-disassociate instead.N(t_disassociate_floating_ip(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_remove_floating_ip scCst||dS(s1Disassociate a floating IP address from a server.N(RI(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_floating_ip_disassociate scCs&t||i}|i|idS(N(RRtremove_floating_ipR(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRI stsecgroups sName of Security Group.cCs&t||i}|i|idS(s!Add a Security Group to a server.N(RRtadd_security_groupRM(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_add_secgroup scCs&t||i}|i|idS(s&Remove a Security Group from a server.N(RRtremove_security_groupRM(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_remove_secgroup scCs,t||i}|i}t|dS(s#List Security Group(s) of a server.N(RRtlist_security_groupt_print_secgroups(R:RSRR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_list_secgroup s tpoolss$Name of Floating IP Pool. (Optional)cCs#t|iid|igdS(s.Allocate a floating IP for the current tenant.RUN(R@R?RRU(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_floating_ip_create ssIP of Floating IP.cCsg|ii}x5|D]-}|i|ijo|ii|iSqWtitd|idS(sDe-allocate a floating IP.sFloating IP %s not found.N( R?R3RlRRRRR{R(R:RSR?t floating_ip((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_floating_ip_delete scCst|iidS(sList floating IPs.N(R@R?R3(R:R((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_floating_ip_list scCs ti|iidgdS(sList all floating IP pools.RN(R Rtfloating_ip_poolsR3(R:R((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_floating_ip_pool_list ssFilter by host.cCs2ti|ii|idddddgdS(s*List all floating IPs (nova-network only).RRt instance_uuidRUt interfaceN(R Rtfloating_ips_bulkR3R6(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_floating_ip_bulk_list s tip_rangessAddress range to create.s--poolssPool for new Floating IPs.s --interfaces sInterface for new Floating IPs.cCs#|ii|i|i|idS(s6Bulk create floating IPs by range (nova-network only).N(R^RR`RUR](R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_floating_ip_bulk_create s sAddress range to delete.cCs|ii|idS(s6Bulk delete floating IPs by range (nova-network only).N(R^RR`(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_floating_ip_bulk_delete scCsti|dddgdS(NRlRtdomain(R R(t dns_entries((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_print_dns_list scCs ti|ddddgdS(NRctscopeRRo(R R(tdomain_entries((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_print_domain_list scCs|ii}t|dS(s&Print a list of available dns domains.N(t dns_domainstdomainsRh(R:RSRj((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_dns_domains sRcss DNS domain.ss IP address.s DNS name.cCs|ip|iptitdn|io,|ii|i|i}t|gn)|ii |id|i}t|dS(s>List current DNS entries for domain and IP or domain and name.s&You must specify either --ip or --nameRlN( RlRRR{RRdRPRcRet get_for_ip(R:RStentrytentries((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_dns_list s  s--typessDNS type (e.g. "A")tAcCs)|ii|i|i|i|idS(s,Create a DNS entry for domain, name, and IP.N(RdRRcRRlR(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_dns_create! s cCs|ii|i|idS(sDelete the specified DNS entry.N(RdRRcR(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_dns_delete. scCs|ii|idS(s Delete the specified DNS domain.N(RiRRc(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_dns_delete_domain5 ssJLimit access to this domain to servers in the specified availability zone.cCs|ii|i|idS(s Create the specified DNS domain.N(Ritcreate_privateRcRo(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_dns_create_private_domain; s s --projects s>Limit access to this domain to users of the specified project.cCs|ii|i|idS(s Create the specified DNS domain.N(Rit create_publicRcR(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_dns_create_public_domainK scCs{dtfdY}g}|D]}|||q!~}ddddg}|o|idnti||dS(Nt FormattedRulecBseZdZRS(cSst|to|n|ii}x|D]y\}}|djo|id}n'|djod}|id}n|djo d}nt|||q-WdS(NR`R<R!t source_groupRRc(RRLRR7RPRxR(R RR7R.R/((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR"Y s&     (R#R$R"(((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRxX ss IP Protocols From PortsTo PortsIP Ranges Source Group(R)R8R R(trulestshow_source_groupRxRtruleR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_print_secgroup_rulesW s 'cCsti|dddgdS(NR<Rt Description(R R(t secgroups((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRSm scCs5titi|pti|o1y|ii|SWqZti j oqZXnt }x|ii D]}t i ptiipd}tip|ii||_n||ijo:|t j o#td|}ti|n|}qpqpW|t jotitd|n|S(NsUTF-8sSMultiple security group matches found for name '%s', use an ID to be more specific.s#Secgroup ID or name '%s' not found.(R tis_integer_likeRt safe_encodeRt is_uuid_likeRpRPRRRJR3tlocaletgetpreferredencodingR$tstdintencodingRMtPY3RtencodeRt NoUniqueMatchR{(R:RMt match_foundRRR0((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt _get_secgroupq s,      sID or name of security group.tip_protos sIP protocol (icmp, tcp, udp).t from_ports sPort at start of range.tto_ports sPort at end of range.ssCIDR for address range.cCsPt||i}|ii|i|i|i|i|i}t |gdS(sAdd a rule to a security group.N( RRMtsecurity_group_rulesRRRRRR<R}(R:RSRMR|((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_secgroup_add_rule s cCst||i}x|iD]}|do|di|iijon|dt|ijoT|dt|ijo:|dd|ijo"t |g|i i |dSqWt i tddS( s$Delete a rule from a security group.t ip_protocolRRR`R<RsRule not foundN(RRMRztupperRtintRRR<R}RRRR{R(R:RSRMR|((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_secgroup_delete_rule s    sName of security group.t descriptions sDescription of security group.cCs,|ii|i|i}t|gdS(sCreate a security group.N(RpRRRRS(R:RSRM((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_secgroup_create scCsAt||i}|ii||i|i}t|gdS(sUpdate a security group.N(RRMRpRRRRS(R:RStsgRM((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_secgroup_update s cCs3t||i}|ii|t|gdS(sDelete a security group.N(RRMRpRRS(R:RSRM((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_secgroup_delete scCsch|id6}dddg}|io|idn|iid|}ti||dS(s,List security groups for the current tenant.RR<RR~R RN(RR8RpR3R R(R:RSRRR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_secgroup_list s  cCs#t||i}t|idS(s List rules for a security group.N(RRMR}Rz(R:RSRM((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_secgroup_list_rules sRyssID or name of source group.cCst||i}t||i}h}|i|d<|ip|ip |ioh|io|io|iptit dn|ii |d<|i|d<|i|d/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_secgroup_add_group_rule s  cCst||i}t||i}h}|i|d<|ip|ip |iot|io|io|iptit dn|ii |d/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_secgroup_delete_group_rule8 s(  +s2.0s2.1cCs|ii||S(N(tkeypairsR(R:RSRtpub_key((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_keypair_createg ss2.2cCs|ii||d|iS(Ntkey_type(RRR(R:RSRR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRl ss Name of key.s --pub-keys sPath to a public ssh key.s --pub_keys --key-types tsshs!Keypair type. Can be ssh or x509.t start_versionc Cs|i}|i}|o|djotii}qyEttii|i i }z|~}|i}WdQXWqt j o0}t i tdh|d6|d6qXnt||||}|p|i}t|ndS(s+Create a new key pair for use with servers.t-Ns%Can't open or read '%(key)s': %(exc)sRYRa(RRR$RRR~tostpatht expanduserRRRRR{RRR6R#( R:RSRRRRRRR6((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_keypair_addq s    / ! sKeypair name to delete.cCs&t||i}|ii|dS(s!Delete keypair given by its name.N(t _find_keypairRRR(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_keypair_delete scCs ddgS(NRt Fingerprint((R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_get_keypairs_list_columns scCs dddgS(NRR&R((R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR scCs2|ii}t||}ti||dS(s#Print a list of keypairs for a userN(RR3RR R(R:RSRR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_keypair_list scCsC|ii}|id}ti|ttd|dS(Nt public_keysPublic key: %s(RRbRcR R.R#R(Rtkptpk((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_print_keypair s Rs sName of keypair.cCs t||i}t|dS(s%Show details about the given keypair.N(RRR(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_keypair_show scCsti|i|S(sGet a keypair by name.(R R-R(R:R((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR ss --reservedtreservedsInclude reservations count.cCs,|ii|i|ii}t|dS(sDEPRECATED, use limits instead.N(tlimitsRPRR tabsolutet_print_absolute_limits(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_absolute_limits sc Cs dtfdY}hhdd6dd6d6hdd6dd6d 6hd d6dd6d 6hd d6dd6d 6hdd6dd6d6hdd6dd6d6hdd6dd6d6hdd6dd6d6hdd6dd6d6hdd6dd6d6hdd6dd6d6hdd6dd6d6hdd6dd6d6hdd6dd6d6hdd6dd6d6hd d6dd6d!6hd"d6dd6d#6hd"d6dd6d$6hd%d6dd6d&6}h}h}h}g}d'd(d)g}x|D]}|i|ih|id6d*d6} | d} | ddjo|i|| /tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR" s   (R#R$R"(((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR ss Server MetaRRRt maxServerMetat PersonalitytmaxPersonalitysPersonality SizetmaxPersonalitySizet ImageMetat maxImageMetatKeypairstmaxTotalKeypairstCoresRttotalCoresUsedt maxTotalCorestRAMt totalRAMUsedtmaxTotalRAMSizet InstancesttotalInstancesUsedtmaxTotalInstancest FloatingIpsttotalFloatingIpsUsedtmaxTotalFloatingIpstSecurityGroupsttotalSecurityGroupsUsedtmaxSecurityGroupstSecurityGroupRulestmaxSecurityGroupRulest ServerGroupstmaxServerGroupsttotalServerGroupsUsedtServerGroupMemberstmaxServerGroupMembersRtUsedtMaxRtOtherRN(R)RPRRZR8RrR R( RRt limit_mapRRRt limit_namesRtlRRt limit_list((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR s`&     cCs |iii}t|dS(sDEPRECATED, use limits instead.N(RRPtratet_print_rate_limits(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_rate_limits scCs,ddddddg}ti||dS(sprint rate limits.tVerbtURItValuetRemaintUnittNext_AvailableN(R R(RR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR scCs9|ii|i|i}t|it|idS(sPrint rate and absolute limits.N(RRPRR RRRR(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_limits# s s--startss<Usage range start date ex 2012-01-20. (default: 4 weeks ago)s--endss8Usage range end date, ex 2012-01-20. (default: tomorrow)c s,d}dddddgti}|iotii|i|}n|tidd}|iotii|i|}n|tid d }fd }|ii||d t }t t d h|i |d6|i |d6x|D]}||qWt i|dS(s List usage data for all tenants.s%Y-%m-%ds Tenant IDtServerss RAM MB-Hourss CPU Hourss Disk GB-Hourstweeksitdaysicsg}D]}||iiddq ~}t||d|it||ddt|it||dd|it||dd|it||d d|idS( Nt Riis%dis%.2fii( RtreplaceRRRt server_usagesttotal_memory_mb_usagettotal_vcpus_usagettotal_local_gb_usage(tuRtxt simplerows(trows(s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytsimplify_usageS s 3!Rxs Usage from %(start)s to %(end)s:RtendN(RtutcnowRtdatetimetstrptimet timedeltaRtusageR3RQR#RtstrftimeR R( R:RSt dateformattnowRRRt usage_listR((Rs>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_usage_list7 s&        s s UUID of tenant to get usage for.c sd}ddddgti}|iotii|i|}n|tidd}|iotii|i|}n|tidd }fd }|io|ii |i||}nut |i t i o@|i i }|i|i ii} |ii | ||}n|ii |i i||}ttd h|i|d 6|i|d 6t|ddo!||ti|gnttddS(s$Show usage data for a single tenant.s%Y-%m-%dRs RAM MB-Hourss CPU Hourss Disk GB-HoursRiRicsg}D]}||iiddq ~}t||ddt|it||dd|it||dd|it||dd|idS( NRRis%dis%.2fii(RRRRRRRR(RRRR(R(s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR s 3!s Usage from %(start)s to %(end)s:RRRRxN(RRRRRRRR RRPRRt SessionClienttautht get_auth_reftsessionRRR#RRRRxR R( R:RSRRRRRRRR((Rs>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_usageh s0       t pk_filenamesspk.pems/Filename for the private key. [Default: pk.pem]t cert_filenamesscert.pems7Filename for the X.509 certificate. [Default: cert.pem]c CsOtii|io titd|intii|io titd|in|ii }ziti d}t |idi i }z4|~}|i|ittd|iWdQXWdti |Xt |idi i }z4|~}|i|ittd|iWdQXdS(s&Create x509 cert for a user in tenant.s'Unable to write privatekey - %s exists.s&Unable to write x509 cert - %s exists.itwsWrote private key to %sNsWrote x509 certificate to %s(RRtexistsR RR{RR tcertsRtumaskR~RRRR6R#R*(R:RSRt old_umaskRR6R tcert((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_x509_create_cert s )!)tfilenames s cacert.pems%Filename to write the x509 root cert.cCstii|io titd|int|idii }zC|~}|i i }|i |i ttd|iWdQXdS(sFetch the x509 root cert.sQUnable to write x509 root cert - %s exists.RsWrote x509 root cert to %sN(RRRRRR{RR~RRRRPRR*R#(R:RSRRtcacert((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_x509_get_root_cert s )s --hypervisors sType of hypervisor.cCsD|ii|i}dddddddg}ti||dS( sList all builds.tAgent_idt HypervisortOSt ArchitecturetVersiontMd5hashR'N(tagentsR3t hypervisorR R(R:RStresultR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_agent_list s Rss Type of OS.t architecturessType of architecture.tversions sVersion.RssURL.tmd5hashs s MD5 hash.RtxencCsM|ii|i|i|i|i|i|i}ti |i i dS(sCreate new agent build.N( RRRR"R#RR$RR R.RRb(R:RSR ((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_agent_create s sID of the agent-build.cCs|ii|idS(sDelete existing agent build.N(RRR(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_agent_delete stURLcCs;|ii|i|i|i|i}ti|idS(sModify existing agent build.N( RRRR#RR$R R.R(R:RSR ((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_agent_modify scCsti|i|S(sGet a aggregate by name or ID.(R R-t aggregates(R:t aggregate((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_find_aggregate scCs2|ii}dddg}ti||dS(sPrint a list of all aggregates.R<RsAvailability ZoneN(R*R3R R(R:RSR*R((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_aggregate_list ssName of aggregate.Ros2The availability zone of the aggregate (optional).cCs)|ii|i|i}t|dS(s2Create a new aggregate with the specified details.N(R*RRRot_print_aggregate_details(R:RSR+((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_aggregate_create s R+s s"Name or ID of aggregate to delete.cCs=t||i}|ii|ttd|idS(sDelete the aggregate.s+Aggregate %s has been successfully deleted.N(R,R+R*RR#RR(R:RSR+((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_aggregate_delete' ss"Name or ID of aggregate to update.s'The availability zone of the aggregate.cCszt||i}h|id6}|io|i|d/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_aggregate_update2 s  sTMetadata to add/update to aggregate. Specify only the key to delete a metadata item.cCst||i}t|}t|dh}t|it|i@otitdnxQ|iD]C\}}|djo*||jotitd|qyqyW|i i |i |}t td|i t|dS(s2Update the metadata associated with the aggregate.R6smetadata already existss7metadata key %s does not exist hence can not be deleteds8Metadata has been successfully updated for aggregate %s.N(R,R+RRR4R7RR{RRxR*t set_metadataRR#R.(R:RSR+R6tcurrentmetadataRYRZ((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_aggregate_set_metadataI s  #   sName or ID of aggregate.s!The host to add to the aggregate.cCsct||i}|ii|i|i}ttdh|id6|id6t|dS(s(Add the host to the specified aggregate.sIHost %(host)s has been successfully added for aggregate %(aggregate_id)s R6t aggregate_idN( R,R+R*tadd_hostRR6R#RR.(R:RSR+((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_aggregate_add_hostf s   s&The host to remove from the aggregate.cCsct||i}|ii|i|i}ttdh|id6|id6t|dS(s7Remove the specified host from the specified aggregate.sLHost %(host)s has been successfully removed from aggregate %(aggregate_id)s R6R6N( R,R+R*t remove_hostRR6R#RR.(R:RSR+((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_aggregate_remove_hostv s   cCs t||i}t|dS(s(Show details of the specified aggregate.N(R,R+R.(R:RSR+((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_aggregate_details scCsXdddddg}d}d}h|d6|d6}ti|g|d|dS( NR<RsAvailability ZonetHoststMetadatacSs tit|dhphS(NR6(R tpretty_choice_dictR(R%((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytparser_metadata scSstit|dgS(Nthosts(R tpretty_choice_listR(R%((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt parser_hosts sR(R R(R+RR?RBR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR. s   sDestination host name.s--block-migratet block_migrates?True in case of block_migration. (Default=False:live_migration)s--block_migrates--disk-over-committdisk_over_commits!Allow overcommit. (Default=False)s--disk_over_commitcCs,t||ii|i|i|idS(s(Migrate running server to a new machine.N(RRt live_migrateR6RCRD(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_live_migration ss--activetstateRRsURequest the server be reset to "active" state instead of "error" state (the default).cCst}x|iD]x}y:t||i|id}t|||ifWqtj o)}t}d||f}t|qXqW|od}ti |ndS(sReset the state of a server.s4Reset state for server %s succeeded; new state is %ss$Reset state for server %s failed: %ss6Unable to reset the state for the specified server(s).N( RJRRt reset_stateRGR#RiRQRR{(R:RSt failure_flagRR0R((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_reset_state s  cCst||iidS(sReset network of a server.N(RRt reset_network(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_reset_network ss Name of host.s--binaryssService binary.cCs|iid|id|i}ddddddg}|o%t|d d o|id n|o(t|d d o|id d nti||dS(s=Show a list of all running services. Filter by host & binary.R6tbinarytBinarytHosttZoneRXtStatet Updated_atitdisabled_reasonsDisabled ReasonRR<N( tservicesR3R6RMRR8RR R(R:RSR R((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_service_list s !RMcCs;|ii|i|i}ti|gdddgdS(sEnable the service.RORNRXN(RTtenableR6RMR R(R:RSR ((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_service_enable ss--reasonssReason for disabling service.cCs|ioD|ii|i|i|i}ti|gddddgn8|ii|i|i}ti|gdddgdS(sDisable the service.RORNRXsDisabled ReasonN(treasonRTtdisable_log_reasonR6RMR Rtdisable(R:RSR ((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_service_disables  s2.11s--unsett force_downs&Unset the force state down of service.t store_falsecCsA|ii|i|i|i}ti|gdddgdS(sForce service to down.RORNs Forced downN(RTR\R6RMR R(R:RSR ((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_service_force_downs !sID of service.cCs|ii|idS(sDelete the service.N(RTRR(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_service_delete#ss2.3cCs)ddddg}ti|g|dS(NRR<thostnameR6(R R(R:tfixed_ipR%((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_print_fixed_ip)ss2.4cCs,dddddg}ti|g|dS(NRR<R`R6R(R R(R:RaR%((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRb/sRas sFixed IP Address.cCs&|ii|i}t||dS(sRetrieve info on a fixed IP.N(t fixed_ipsRPRaRb(R:RSR ((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_fixed_ip_get5scCs|ii|idS(sReserve a fixed IP.N(RctreserveRa(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_fixed_ip_reserve<scCs|ii|idS(sUnreserve a fixed IP.N(Rct unreserveRa(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_fixed_ip_unreserveBscCs>|ii|i}dddddg}ti||dS(sDescribe a specific host.tHOSTtPROJECTtcpuRtdisk_gbN(R@RPR6R R(R:RSR R((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_host_describeHss--zonessMFilters the list, returning only those hosts in the availability zone .cCs8dddg}|ii|i}ti||dS(sList all hosts by service.t host_nametservicetzoneN(R@R3RpR R(R:RSRR ((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_host_listPsss Either enable or disable a host.s --maintenancet maintenances.Either put or resume host to/from maintenance.cCsh}dg}|io|i|d<|idn|io|i|d<|idn|ii|i|}ti|g|dS(sUpdate host settings.RiRtmaintenance_modeN(RR8RrR@RR6R R(R:RSR1RR ((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_host_update]s      s--actiontstartupRs-A power action: startup, reboot, or shutdown.cCs8|ii|i|i}ti|gddgdS(s!Perform a power action on a host.Rit power_actionN(R@t host_actionR6R[R R(R:RSR ((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_host_actionuscCsti|i|S(sGet a hypervisor by name or ID.(R R-t hypervisors(R:R((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_find_hypervisorss --matchings/List hypervisors matching the given .cCs_ddddg}|io#ti|ii|i|nti|iit|dS(sList hypervisors.RsHypervisor hostnameRQRXN(tmatchingR RRytsearchR3RJ(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_hypervisor_lists #R`s3The hypervisor hostname (or pattern) to search for.c Cs|ii|idt}dtfdY}g}x|D]z}|i}|i}t|doR|ig}|i D]0} ||d| dd| dd|d|qz~q>q>Wt i |d d d d gd S(s/List servers belonging to specific hypervisors.R tInstanceOnHypercBseZdZRS(c[s|ii|dS(N(RR(R R((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR"s(R#R$R"(((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR~sRRRthypervisor_hostnamet hypervisor_idRRs Hypervisor IDsHypervisor HostnameN( RyR|R`RQR)RRRtextendR R R( R:RSthypersR~t instancesthypert hyper_hostthyper_idRtserv((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_hypervisor_serverss   Is4Name or ID of the hypervisor to show the details of.s--wrapRs i(sDWrap the output to a specified length. Default is 40 or 0 to disablecCs>t||i}titi|idt|idS(s0Display the details of the specified hypervisor.RN(RzRR R.t flatten_dictRRR(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_hypervisor_shows s3Name or ID of the hypervisor to show the uptime of.cCs>t||i}|ii|}ti|iidS(s/Display the uptime of the specified hypervisor.N(RzRRytuptimeR R.RRb(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_hypervisor_uptimescCs)|ii}ti|iidS(s1Get hypervisor statistics over all compute nodes.N(thypervisor_statst statisticsR R.RRb(R:RStstats((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_hypervisor_statsscCsEt|idp.|ii|iit|iindS(Ntservice_catalog(RRtunauthenticatetuse_token_cacheRJt authenticate(R:((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytensure_service_catalog_presents cCst|itioR|ii}|i|iii}xv|iD]}t||ii qGWnLt ||iii }|ii }x#|ddD]}t||qWdS(sDDiscover endpoints that get returned from the authenticate services.taccesstserviceCatalogN( RRRRt get_accessR Rtget_datat_print_endpointst region_nameRtcatalog(R:RRtscRoRtregion((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_endpointss    cCs|d|d}}y#t||}ti||WnVtj oJttdh|d6|d6x#|D]}ti||qrWnXdS(NRt endpointssYWARNING: %(service)s has no endpoint in %(region)s! Available endpoints for this service:RoR(t_get_first_endpointR R.t LookupErrorR#R(RoRRRtendpointtother_endpoint((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRs cCsSt|djo |dSx$|D]}|d|jo|Sq#WtddS(s6Find the first suitable endpoint in endpoints. If there is only one endpoint, return it. If there is more than one endpoint, return the first one with the given region. If there are no endpoints, or there is more than one endpoint but none of them match the given region, raise KeyError. iiRsNo suitable endpoint foundN(RR(RRtcandidate_endpoint((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRs   i@s7Wrap PKI tokens to a specified length, or 0 to disable.cCst|itios|ii}|i|iii}ti|i dddt |i ti|i ddt |i nht ||iii }ti|ddddt |i ti|ddddt |i dS(s)Show user credentials returned from auth.RpsUser CredentialsRtTokenRttokenN(RRRRRR RR R.RRRt get_tokenR(R:RRRR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_credentials s ) s--porttstoreisAOptional flag to indicate which port to use for ssh. (Default=22)s --privatetprivates--address-typet address_typetfloatingskOptional flag to indicate which IP type to use. Possible values includes fixed and floating (the Default).s --networksNetwork to use for the ssh.s--ipv6tipv6siOptional flag to indicate whether to use an IPv6 address attached to a server. (Defaults to IPv4 address)s--loginss Login to use.troots-is --identitytidentitys;Private key file, same as the -i option to the ssh command.Rcs --extra-optstextras+Extra options to pass to ssh. see: man ssh.c sd|ijo1|iidd\}}||_||_nt||ii}|iodn|i|iodndd}|ioT|i |i}|p7t d}t i |h|id6|id 6q|nt |djo-t d }t i|h|id6nN|p-t d }t i|h|id6ntti|d }fd }g} |D]'} || o| | i dqq~ } t| pEt d}t i |h|id 6d6|d6|id6nOt | djo1t d}t i|h|d6d6n | d } t |iod|ind} d|i| |i| |if}tid|ti|dS(sSSH into a server.t@itfixediisIPv%ds<Server '%(server)s' is not attached to network '%(network)s'RRsYServer '%(server)s' is attached to more than one network. Please pick the network to use.s3Server '%(server)s' is not attached to any network.ics1t|idj|iddjfS(R#sOS-EXT-IPS:typeR(RRP(taddr(RR#(s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRosRsNo address that would match network '%(network)s' and type '%(address_type)s' of version %(pretty_version)s has been found for server '%(server)s'.Rtpretty_versions?More than one %(pretty_version)s %(address_type)s addressfound.s-i %sRcsssh -%d -p%d %s %s@%s %ssExecuting cmd '%s'N(RR)tloginRRRRRRRPRRtResourceNotFoundRR{R3RMt itervaluestanyRRRtloggertdebugRtsystem(R:RSRpRRRtnetwork_addressesR0R>RRtmatching_addressest ip_addressRtcmd((R#Rs>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_ssh sN0     ) ! !4     $RtcoresR?Rctmetadata_itemstinjected_filestinjected_file_content_bytestinjected_file_path_bytest key_pairsRpRt server_groupstserver_group_membersc CsdtfdY}g}xMtD]E}y)||t||}|i|Wq#tj oq#Xq#Wddg}ti||dS(NtFormattedQuotacBseZdZRS(cSs$t|d|t|d|dS(NtquotaRT(R(R RYRZ((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR"s(R#R$R"(((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRstQuotaR(R)t_quota_resourcesRR8R9R R(R Rt quota_listtresourceRR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt _quota_shows  c Csh}x;tD]3}t||d}|dj o|||/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt _quota_updates  s$ID of tenant to list the quotas for.s s"ID of user to list the quotas for.cCs|io |i}nKt|itio(|ii}|i|iii}n |ii}t |i i |d|i dS(s"List the quotas for a tenant/user.RtN( R RRRRR R RRRR RPRp(R:RSRR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_quota_shows    s,ID of tenant to list the default quotas for.cCs{|io |i}nKt|itio(|ii}|i|iii}n |ii}t |i i |dS(s%List the default quotas for a tenant.N( R RRRRR R RRRR tdefaults(R:RSRR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_quota_defaultss    s#ID of tenant to set the quotas for.s!ID of user to set the quotas for.s --instancess s$New value for the "instances" quota.s--coresss New value for the "cores" quota.s--ramsNew value for the "ram" quota.s--floating-ipsss'New value for the "floating-ips" quota.s--floating_ipss --fixed-ipss s$New value for the "fixed-ips" quota.s--metadata-itemsss)New value for the "metadata-items" quota.s--metadata_itemss--injected-filesss)New value for the "injected-files" quota.s--injected_filess--injected-file-content-bytesss6New value for the "injected-file-content-bytes" quota.s--injected_file_content_bytess--injected-file-path-bytesss3New value for the "injected-file-path-bytes" quota.s --key-pairss s$New value for the "key-pairs" quota.s*New value for the "security-groups" quota.s--security-group-rulesss/New value for the "security-group-rules" quota.s--server-groupsss(New value for the "server-groups" quota.s--server-group-membersss/New value for the "server-group-members" quota.Rs[Whether force update the quota even if the already used and reserved exceeds the new quota.cCst|i|i|dS(s$Update the quotas for a tenant/user.N(RR R (R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_quota_updatesttrequireds!ID of tenant to delete quota for.sID of user to delete quota for.cCs |ii|id|idS(sVDelete quota for a tenant/user so their quota will Revert back to default. RtN(R RR Rp(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_quota_deleteYst class_namess+Name of quota class to list the quotas for.cCst|ii|idS(s"List the quotas for a quota class.N(Rt quota_classesRPR(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_quota_class_showjss*Name of quota class to set the quotas for.cCst|i|i|dS(s$Update the quotas for a quota class.N(RRR(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_quota_class_updatetshsWName or ID of the target host. If no host is specified, the scheduler will choose one.sdSet the provided admin password on the evacuated server. Not applicable with on-shared-storage flag.s--on-shared-storageton_shared_storages=Specifies whether server files are located on shared storage.cCs\t||i}|i|i|i|id}t|tjoti |ndS(s!Evacuate server from failed host.iN( RRtevacuateR6RRRRLR R.(R:RSRtres((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt do_evacuates"csfdddddgdtffdY}tig}|D]}|||qB~dS(Ns Port StatesPort IDsNet IDs IP addressessMAC AddrtFormattedInterfacecseZfdZRS(csxSD]K}|iidd}t||ot||t||qqWdig}|iD]}||dqj~|_dS(NRRRDR(RRRRRRRct ip_addresses(R R]tcolRYRtfip(R(s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyR"s! (R#R$R"((R(s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRs(R)R R(t interfacesRRti((Rs>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_print_interfacess  cCsCt||i}|i}t|tjot|ndS(s%List interfaces attached to a server.N(RRtinterface_listRR3R(R:RSRR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_interface_list s s --port-ids sPort ID.tport_ids--net-idss Network IDtnet_ids --fixed-ipsRequested fixed IP.cCsXt||i}|i|i|i|i}t|tjoti |ndS(s'Attach a network interface to a server.N( RRtinterface_attachRRRaRRLR R.(R:RSRR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_interface_attachscCsLt||i}|i|i}t|tjoti|ndS(s)Detach a network interface from a server.N(RRtinterface_detachRRRLR R.(R:RSRR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_interface_detach,sc Csti}||iti|i|i}g}|i|_|idodnd|_|i|id<|i|id<|i ||i dj oYt |i i dd}x8|D],\}}||iti|i|i}d||_d|_|i|id<|i|id<|i |x|i D]\}}||iti|i|i}d ||_d |d od nd |dodnd|df|_|i|id<|i|id<|i |q?WqWn|S(s)Build a tree view for availability zones.t availables not availableRRRYcSs|dS(i((R((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyRHss|- %sRcs| |- %ss%s %s %sRtenabledtdisableds:-)tXXXt updated_atN(R tAvailabilityZoneRRbtdeepcopyRt_loadedRRR8R@RxRR7( RpRtazR t zone_hostsR6RTtsvcRG((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_treeizeAvailabilityZone7sB            tcomputec Csy|ii}WnMtij o>}y|iidt}Wqctj o |qcXnXg}x|D]}|t|7}qpWt|ti |ddgdddS(s List all the availability zones.RxRRXRYN( R R3Rt ForbiddenRJRiRRR RRx(R:RR RR Rp((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_availability_zone_listbs cCsUt|doddddddg}ndddddg}ti||dS(NRR<Rt Project_idtPoliciestMembersR=(RR R(t server_groupR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyt_print_server_group_detailsus  s--all-projectst all_projectss5Display server groups from all projects (Admin only).cCs#|ii|i}t|dS(s"Print a list of all server groups.N(RR3RR(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_server_group_listscCst|iidtdS(sWList rules that will be added to the 'default' security group for new tenants. R{N(R}tsecurity_group_default_rulesR3RJ(R:RS((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_secgroup_list_default_rulesscCs>|ii|i|i|i|i}t|gdtdS(sAdd a rule to the set of rules that will be added to the 'default' security group for new tenants (nova-network only). R{N(R RRRRR<R}RJ(R:RSR|((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_secgroup_add_default_rules  cCsx|iiD]}|io|ii|iijop|it|ijoW|it|ijo>|id|i jo't |gdt |ii |i SqWtitddS(sDelete a rule from the set of rules that will be added to the 'default' security group for new tenants (nova-network only). R<R{sRule not foundN(R R3RRRRRRR`R<R}RJRRRR{R(R:RSR|((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_secgroup_delete_default_rules sServer group name.tpolicyst*s?Policies for the server groups. ("affinity" or "anti-affinity")s--policycCs`|iptitdnh|id6|id6}|ii|}t|gdS(s5Create a new server group with the specified details.s%at least one policy must be specifiedRtpoliciesN(RRR{RRRRR(R:RSRR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_server_group_creates    s+Unique ID(s) of the server group to delete.cCsd}x}|iD]r}y(|ii|ttd|Wqtj o5}|d7}ttdh|d6|d6qXqW|t|ijotitdndS( s Delete specific server group(s).is.Server group %s has been successfully deleted.is,Delete for server group %(sg)s failed: %(e)sRRs4Unable to delete any of the specified server groups.N( RRRR#RRiRRR{(R:RSt failure_countRR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_server_group_deletes   s%Unique ID of the server group to get.cCs&|ii|i}t|gdS(sGet a specific server group.N(RRPRR(R:RSR((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_server_group_getscCsb|ii}dt|djodddddg}ndddg}ti||dS( sList all API versions.t min_versioniR<RXtUpdateds Min VersionRN(tversionsR3tdirR R(R:RSR R((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pytdo_version_list s (t __future__RR+RbRRRtloggingRR$Rt oslo_utilsRRRRRMt novaclientRRRtnovaclient.i18nRtnovaclient.openstack.commonR R t novaclient.v2R R R t getLoggerR#RROR'R1R@R_RtargRxRtSUPPRESStenvironRPRJRRRRRQRRRRRRRRRRR RRRR"R,R/R0R5R8R:RORSR[R^RRgRRhRjRRt REBOOT_HARDt REBOOT_SOFTRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRwR}RRRRRRRRRRRRRR R RRRRRRRRRR+R.R1R5R8R:R@RCRERFRDRJRKRIRORQRTRVRXRYR[R_RaRbReRhRkRoRqRrRsRuRwR}RSRRRRRRRRRRtwrapsRRRRRRRRRRRRRRR RRR!R&R'R)R,R-R/R0R2R5R8R:R;R.RFRJRLRURWR[R^R_RbRdRfRhRmRqRtRxRzR}RRRRRRRRRRRRRRRRRRRRRRRRRRt service_typeRRR R R R RRRR(((s>/tmp/pip-build-cD3xZi/python-novaclient/novaclient/v2/shell.pyts~             8                            l -.                 *                                      Z                          Nc            3(  -  ** **    **** *****  **  !   !     6 -    -                     0              $     *  -- * *        $6 -*          6     6          $    $   *     >     (   /    ' *3                    $  * -  *****                  *>                             T                       N  ! *     ! - +     3    3