ó ¡ôXc@ sîddlmZddlZddlmZddlmZddlmZddl m Z m Z ddl m Z ddlmZdd lmZdd lmZdd lmZdd lmZmZd eeee e fd„ƒYZdS(iÿÿÿÿ(tdivisionN(tArg(tQueryHmacV2Auth(t ClientError(tFileTransferProgressBarMixintTabifyingMixin(tEC2(t RegisterImage(tBootstrapRequest(t S3Request(tBundleAndUploadImage(tBundleCreatingMixintBundleUploadingMixint InstallImagecB sþeZdZedddddeddƒedddddƒed d ed d dd ƒedddddddƒeddddddd ddƒedddddƒeddddejƒeddddejƒgZ d„Z d„Z d„Z RS(!s3Bundle, upload and register an image into the clouds-ns--nametroute_totrequiredthelps name of the new image (required)s --descriptionsdescription of the new images--max-pending-partsttypetdefaultisvpause the bundling process when more than this number of parts are waiting to be uploaded (default: 2)s--virtualization-typetchoicest paravirtualthvms%virtualization type for the new images --platformtmetavartwindowss/[Privileged] the new image's platform (windows)s --ec2-urlscompute service endpoint URLs --ec2-auths --ec2-servicecC s|jƒtj|ƒ|jjdƒsWtj|jd|jjdƒƒ|jdbootstrap setup failed; auto cert fetching will be unavailabletexc_info(tconfigure_bundle_upload_authR t configuretargstgetRt from_othertserviceRtauthtlogtwarnRt SERVICE_CLASSt AUTH_CLASSRtdebugtTruetconfigure_bundle_credstconfigure_bundle_propertiestconfigure_bundle_output(tself((sJ/usr/lib/python2.7/site-packages/euca2ools/commands/bundle/installimage.pyR!As*  (%% %     c+C stj|d|jdd|jdd|jdd|jjdƒd|jjdƒd|jjdƒd|jjdƒd|jjdƒd |jjd ƒd |jjd ƒd |jjd ƒd |jjd ƒd |jjd ƒd|jjdƒd|jjdƒd|jjdƒd|jjdƒd|jjdƒd|jjdƒd|jjdƒƒ}|jƒ}|ddd}tj|d|jdd|jdd|jdd|jdd|d |jjd!ƒd"|jjd#ƒd$|jjd%ƒƒ}|jƒ}|S(&Ntimagetarchtbuckettprefixt destinationtkerneltramdiskt image_typet image_sizetcertt privatekeytec2certtusert productcodestenc_ivtenc_keytmax_pending_partst part_sizetbatcht show_progresst manifestsitkeyR%RR&RtNametnamet Architecturet ImageLocationt Descriptiont descriptiontVirtualizationTypetvirtualization_typetPlatformtplatform(R R$R"R#tmainR(R0treqt result_bundletimage_locationtresult_register((sJ/usr/lib/python2.7/site-packages/euca2ools/commands/bundle/installimage.pyRQes2 $$$$$   cC s!|jd|jdƒfƒGHdS(NtIMAGEtimageId(ttabifyR#(R0tresult((sJ/usr/lib/python2.7/site-packages/euca2ools/commands/bundle/installimage.pyt print_resultsN(RR(R( t__name__t __module__t DESCRIPTIONRtNoneR,tinttargparsetSUPPRESStARGSR!RQRZ(((sJ/usr/lib/python2.7/site-packages/euca2ools/commands/bundle/installimage.pyR ,s( $ (t __future__RR`trequestbuilderRtrequestbuilder.auth.awsRtrequestbuilder.exceptionsRtrequestbuilder.mixinsRRteuca2ools.commands.ec2Rt$euca2ools.commands.ec2.registerimageRteuca2ools.commands.bootstrapRteuca2ools.commands.s3R t.euca2ools.commands.bundle.bundleanduploadimageR t euca2ools.commands.bundle.mixinsR R R (((sJ/usr/lib/python2.7/site-packages/euca2ools/commands/bundle/installimage.pyts