#NEWLINE# def upload( self , local_filepath , aws_filepath ) : #NEWLINE# #INDENT# '\n        Uploads `local_filepath` to `aws_filepath`.\n\n        Returns the published URL for the file.\n        ' #NEWLINE# logging . info ( ( 'Publishing %s to %s' % ( local_filepath , aws_filepath ) ) ) #NEWLINE# key = Key ( bucket = self . bucket , name = local_filepath ) #NEWLINE# key . key = aws_filepath #NEWLINE# key . set_contents_from_filename ( local_filepath ) #NEWLINE# key . set_acl ( 'public-read' )