I currently use s3cmd to download a file from s3. However I'd rather output the contents to STOUT. Do you know a unix tool that can do it?
Thanks, Jan
You can download an object from an S3 bucket in any of the following ways: Select the object and choose Download or choose Download as from the Actions menu if you want to download the object to a specific folder. If you want to download a specific version of the object, select the Show versions button.
In the Amazon S3 console, choose your S3 bucket, choose the file that you want to open or download, choose Actions, and then choose Open or Download. If you are downloading an object, specify where you want to save it. The procedure for saving the object depends on the browser and operating system that you are using.
Your answer All file objects must have their contents written to stdout. To get this, use the aws s3 cp command and provide "-" as the destination. $ aws s3 cp s3:/mybucket/stream.
You'll need to add -
to the end of you command arguments to make it redirect the output to STDOUT.
Example : s3cmd get s3://... -
See this thread for more information.
You might also use the --no-progress
option to avoid extra information in the output and just get the plain file content
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With