Security News
Weekly Downloads Now Available in npm Package Search Results
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.
archive-stream-to-s3
Advanced tools
A stream for writing the contents of a tar file to s3
const { ArchiveStreamToS3 } = require("archive-stream-to-s3");
const gunzip = require("gunzip-maybe");
const toS3 = new ArchiveStreamToS3("my-bucket", "some/prefix/to/add", s3, [
/.*foo.txt$/
]);
toS3.on("finish", () => {
console.log("upload completed");
});
toS3.on("error", e => {
console.error(e);
});
const archive = fs.createReadStream("archive.tgz");
//Note: if you have compressed archive you can decompress w/ gunzip-maybe.
archive.pipe(gunzip()).pipe(toS3);
You can also use the promise
function that has gunzip built in.
const { promise } = require("archive-stream-to-s3");
const archive = fs.createReadStream("archive.tgz");
promise("my-bucket", "prefix", s3, archive).then(result => {
console.log(result); //=> { keys: [...]}
});
npm run test
For integration tests to run you'll need to set the following env vars:
name | purpose |
---|---|
ARCHIVE_STREAM_TO_S3_TEST_BUCKET | the s3 bucket, this bucket is removed and recreated |
ARCHIVE_STREAM_TO_S3_TEST_PREFIX | the prefix to use |
You'll also need the aws-cli commands on your path.
npm run it
npm run release
FAQs
A stream for writing the contents of a tar file to AWS S3.
The npm package archive-stream-to-s3 receives a total of 0 weekly downloads. As such, archive-stream-to-s3 popularity was classified as not popular.
We found that archive-stream-to-s3 demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.
Security News
A Stanford study reveals 9.5% of engineers contribute almost nothing, costing tech $90B annually, with remote work fueling the rise of "ghost engineers."
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.