anacronw / multer-s3

multer storage engine for amazon s3
MIT License
660 stars 190 forks source link

Add support for storageClass option #59

Closed franciscotfmc closed 7 years ago

franciscotfmc commented 7 years ago

Added the possibility for specifying the storageClass option:

var upload = multer({
  storage: multerS3({
    s3: s3,
    bucket: 'some-bucket',
    acl: 'public-read',
    storageClass: 'STANDARD_IA',
    key: function (req, file, cb) {
      cb(null, Date.now().toString())
    }
  })
})

I just saw that @gregkeys made a pull request that also includes this modification, but there were some conflict issues. Therefore I also copied his README.md updates about the storageClass and added the docs for my last commit about the contentDisposition header.

Hope it helps.

franciscotfmc commented 7 years ago

@LinusU @badunk Any changes of merging this?

LinusU commented 7 years ago

LGTM 👍

anacronw commented 7 years ago

thanks!