import http.client
http.client.HTTPConnection.debuglevel = 1
conn = boto.connect_s3(aws_access_key_id='some', aws_secret_access_key='some')
b = conn.get_bucket('snappie.watermarks')
k = Key(b)
k.key = 'test.txt'
k.set_contents_from_string('12345')
How to upload a file to s3 from a file upload form after modifying it with PIL?