2.0.1 • Published 10 years ago

s3streamer v2.0.1

Weekly downloads
2
License
BSD-3-Clause
Repository
github
Last release
10 years ago

s3streamer

Stream objects from S3.

build status

Installation

This module is installed via npm:

$ npm install s3streamer

Example Usage

var s3streamer = require('s3streamer')(s3credentials);

var objectKeys = s3streamer.objectKeys({Bucket: process.env.BUCKET, Prefix: 'myprefix'});
// {key: 'blah', bucket: 'thebucketyougave'}, ...

var getObjects = objectKeys.pipe(s3streamerer.getObject());
// {key: 'blah', body: 'contents...'}, ...

s3credentials are passed in to: new AWS:S3(s3credentials), cf Amazon doco here: (http://docs.aws.amazon.com/AWSJavaScriptSDK/latest/AWS/S3.html)

Tests

To run the tests you will need some valid S3 credentials and a corresponding bucket. Ensure the bucket has at least one object with a key prefixed by exists. Run like so:

S3_REGION='us-east-1' S3_ACCESS_KEY_ID='mykeyid' S3_SECRET_ACCESS_KEY='mysecretaccesskey' BUCKET='mybucket' npm test
2.0.1

10 years ago

2.0.0

10 years ago

1.1.2

10 years ago

1.1.1

10 years ago

1.1.0

10 years ago

1.0.2

10 years ago

1.0.1

10 years ago

1.0.0

10 years ago