s3_2.py 191 B

1234567
  1. def s3_delete(id):
  2. s3conn = boto.connect_s3(AWS_ACCESS_KEY,AWS_SECRET_ACCESS_KEY)
  3. bucket = s3conn.get_bucket(S3_BUCKET)
  4. k = Key(bucket)
  5. k.key = 'id-' + str(id)
  6. k.delete()