This library lets you efficiently stream the contents of an S3 bucket/folder as a zip file to the client.
Installation is done via composer by adding the a dependency on limenet/s3-bucket-stream-zip-php.
composer require limenet/s3-bucket-stream-zip-php
composer install
// taken from examples/simple.php
require 'vendor/autoload.php';
use JMathai\S3BucketStreamZip\S3BucketStreamZip;
$stream = new S3BucketStreamZip([
'key' => 'your-key-goes-here',
'secret' => 'your-secret-goes-here',
'bucket' => 'the-name-of-your-bucket',
'region' => 'the-region-of-your-bucket',
'prefix' => 'prefix-of-the-files-to-zip',
]);
$stream->send('name-of-zipfile-to-send.zip');
- Jaisen Mathai jaisen@jmathai.com - http://jaisenmathai.com
- Linus Metzler hi@linusmetzler.me - https://linusmetzler.me
- Paul Duncan pabs@pablotron.org - http://pablotron.org/
- Jonatan Männchen jonatan@maennchen.ch - http://commanders.ch
- Jesse G. Donat donatj@gmail.com - https://donatstudios.com