Viewing File: /usr/lib/python2.7/site-packages/euca2ools/commands/bundle/uploadbundle.pyc
ķ
ĄôXc @ s d d l Z d d l Z d d l Z d d l m Z d d l m Z d d l m Z d d l
m Z d d l m
Z
d d l m Z d e
e e f d YZ d
Z d S( i˙˙˙˙N( t Arg( t FileTransferProgressBarMixin( t BundleManifest( t BundleUploadingMixin( t S3Request( t PutObjectt UploadBundlec B s e Z d Z e d d d d d e d d e d d d d
d d e d d d
d e d d d e j e d d d d d g Z d Z d Z
d Z RS( s: Upload a bundle prepared by euca-bundle-image to the clouds -ms
--manifestt metavart FILEt requiredt helps, manifest for the bundle to upload (required)s -ds --directoryt DIRsh directory that contains the bundle parts (default:
directory that contains the manifest)s --partt INTt typet defaulti s --skipmanifestt actiont
store_trues do not upload the manifestc C s | j t j | d S( N( t configure_bundle_upload_authR t configure( t self( ( sJ /usr/lib/python2.7/site-packages/euca2ools/commands/bundle/uploadbundle.pyR 5 s
c
s | j | j t j | j d } | j j d pT t j j | j d } x\ | j D]Q } t j j
| | j | _ t j j | j sa t
d j | j qa qa Wt j d t \ } } t j d t d | | f } | j | j | j | d | j j d | j
| j j d sē t j j | j d } t j | d | j d d
| d | j j d pd d
| j j d
p§d } | j n d } i t f d | j D d 6i | j d d 6| d 6f d 6S( Nt manifestt directorys no such part: '{0}'t duplext targett argst
show_progresst skipmanifestt sourcet destt acls
aws-exec-readt retriesi c 3 s9 | ]/ } i | j d 6 t j j | j d 6Vq d S( t filenamet keyN( R t ost patht basename( t .0t part( t
key_prefix( sJ /usr/lib/python2.7/site-packages/euca2ools/commands/bundle/uploadbundle.pys <genexpr>` s t partsR R t manifests( t get_bundle_key_prefixt ensure_dest_bucket_existsR t read_from_fileR t getR! R"