Copy file from S3 to Local Storage

Submitted by eric - 6 months ago

Had a need to copy files from Amazon S3 to my local system. This is the solution I ended up using. Working on Laravel 5.6

Storage::disk('local')->put(
    'filename.txt', 
    Storage::disk('s3')->get('cloud-filename.txt'));
comments powered by Disqus