Package madrona :: Package common :: Module s3
[hide private]

Module s3

source code

Lingcod's custom S3 wrapper Provides some useful shortcuts to working with commom AWS S3 tasks

Functions [hide private]
 
s3_bucket(bucket=None)
Shortcut to a boto s3 bucket Uses settings.ACCESS_KEY, settings.AWS_SECRET_KEY defaults to settings.AWS_MEDIA_BUCKET
source code
 
get_s3_url(b, k)
Returns the standard s3 url
source code
 
upload_to_s3(local_path, keyname, mimetype=None, bucket=None, acl='public-read')
Given a local filepath, bucket name and keyname (the new s3 filename), this function will connect, guess the mimetype of the file, upload the contents and set the acl.
source code
Function Details [hide private]

upload_to_s3(local_path, keyname, mimetype=None, bucket=None, acl='public-read')

source code 

Given a local filepath, bucket name and keyname (the new s3 filename), this function will connect, guess the mimetype of the file, upload the contents and set the acl. Defaults to public-read