Amazon S3 bucket listing

Sample Code & Libraries>Amazon S3>Amazon S3 bucket listing
Community Contributed Software

  • Amazon Web Services provides links to these packages as a convenience for our customers, but software not authored by an "@AWS" account has not been reviewed or screened by AWS.
  • Please review this software to ensure it meets your needs before using it.

With this simple script it's possible to add web "directory" listing to Amazon S3 buckets.It produces a list like this with a link to every files in the bucket.

Details

Submitted By: frhack
AWS Products Used: Amazon S3
Language(s): JavaScript
License: GNU General Public License (GPL version 2)
Created On: September 10, 2008 7:25 AM GMT
Last Updated: September 27, 2008 8:53 AM GMT
Download
With this simple script it's possible to add web "directory" listing to Amazon S3 buckets.

It produces a list like this with a link to every files in the bucket.

Usage:

Put the file http://regexp.s3.amazonaws.com/list.html inside a bucket, be sure to make it readable setting the ACL appropriately.

You'll get the bucket content list at the url http://.s3.amazonaws.com/list.html

Update:
v. 1.1 supports HTTPS too

Comments

it works
It works, here is an example : http://regexp.s3.amazonaws.com/list.html
frhack on September 29, 2010 9:41 AM GMT
Broken?
This does not seem to work any more. Only the column headings show. No files are listed. Tried it is several buckets. As far as I know I am using it as directed?...
Dan Vokt on September 29, 2010 8:57 AM GMT
Awesomesauce. One bugfix re: absolute pathnames.
If you put this in a 'subdirectory' (more precisely, a key with a '/' in it), you should change line 114 from link = ""+name+""; to add a frontslash: link = ""+name+""; This should be harmless whereever the file sits; it just makes it use absolute, not relative, pathnames
Philip F. Kromer on June 10, 2009 8:29 PM GMT
Nice Script!
Great little script, easy to install and even easy code to understand. It will be great if there will be a way of making .s3.amazon.com go directly to a file. Similar to what apache does with index.html. Thanks...
Geo on May 7, 2009 1:45 AM GMT
Thank you for this script!
I'm so glad to find this simple, easy way to list the contents of directories. It was a pain having to share a lot of nested urls, or just figure out how to get a list of them without a lot of wasted time cutting and pasting. Thank you!
Lindsay Donaghe on February 9, 2009 6:03 AM GMT
Excellent!
This works exactly as described. It would be nice if it also worked for HTTPS, or for URLs of the form http://s3.amazonaws.com/bucket/ Nevertheless, great tool. Thank you so much.
Gabriel on September 26, 2008 11:30 PM GMT
We are temporarily not accepting new comments.
©2014, Amazon Web Services, Inc. or its affiliates. All rights reserved.