Amazon S3, CNAME record, Panic’s Transmit, and WordPress

Amazon Web Services Simple Storage Service (S3) is the solution for anyone wishing to store or deliver massive amounts of data without eating up precious bandwidth on their own server. Amazon S3 works great for your computer and web hosting needs.

Getting started with Amazon S3

Getting started with Amazon S3 is simple and takes no more than a few minutes. Once registered and confirmed, access to your account can be achieved using your account identifiers and an S3 client like S3Fox, S3Hub, or Transmit.

Want an estimate based on the amount of data, bandwidth, or requests you expect to offload to Amazon S3? Check out the AWS Simple Monthly Calculator.

Your files and the Amazon S3 URL structure

Managing your files on Amazon S3 is not much different from managing files on your own server via FTP. Users need to understand that Amazon uses "buckets" as the top level for your objects. This means that you can separate your different file hosting needs using different buckets. For this introduction to S3 file hosting, we’ll use the example website your-site.com.

The average user may sign up for Amazon S3 hosting and begin uploading files – accepting the default URL structure for hosted files:

http://s3.amazonaws.com/your-bucket/some-file.txt

If you plan on using S3 to host media files – more specifically Flash files – you’ll run into Adobe’s cross domain security policy. The fix requires mapping your hosted S3 files to look as though they are being served from your own domain – virtual hosting. The easiest and most attractive method would be a hosted file URL that like this:

http://s3.your-site.com/some-file.txt

To get started, create a bucket on S3 that you want as the root for your hosted files. For this example, your S3 bucket would be:

s3.your-site.com

The most important step is adding the appropriate CNAME record to your DNS settings.

Name Type Data
s3.your-site.com CNAME s3.amazonaws.com.

Expect your new DNS settings to take up to 24-48 hours to resolve.

Fixing Transmit’s "Copy URL"

The right-click menu for Panic’s Transmit will grab the default Amazon S3 URL path at your-bucket-name.amazonaws.com. To ensure that the path reflects your new subdomain correctly, you will need to edit your S3 connection settings. More specifically, the expected Root URL:

http://s3.your-site.com/

Transmit screenshot

These settings assume that you have a single custom bucket to reflect your S3 hosted files CNAME record.

Amazon S3 file hosting integrated with WordPress

Looking for an even more integrated S3 file hosting with your WordPress install? Check out the Amazon S3 plugin for WordPress. Installation is straightforward. The only requirement aside from an S3 account is that your server be PHP5 enabled.

The S3 WordPress plugin will support the previously configured virtual host s3.your-site.com/some-file.txt and provide direct upload from the post editor window.

Other Amazon S3 bits

To supplement my Time Machine and external SuperDuper backups, I rely on Jungle Disk to do the same in the cloud – the S3 cloud. I enjoy the convenience and peace of mind knowing that my data is safe and easily accessible. That same convenience can be extended to file hosting.

  • S3Hub – View your S3 online storage, upload, download, set permissions, share with friends and more. Also use to view other users’ public buckets.
  • S3Fox Organizer – Manage your S3 buckets using this handy Firefox extension.
  • Shrub – Shrub lists files in public S3 buckets. For when you want to share a bucket with the world.
  • Tutorial: How-to make files public – A walk through if you are not all ready familiar with the world, authenticated users, and owners permissions.
  • FuseOverAmazon – FUSE based file system backups powered by Amazon S3.
  • Getting started with Amazon CloudFront – Paul walks through the steps to get started delivering content via Amazon CloudFront.

Are you using Amazon S3? If so, how? Personal backups, file sharing, development?

Discuss - 6 Comments

  1. Preshit says:

    2 month old user of S3 and I love it. Although I only take backups of my MBP using JungleDisk, I might start hosting files on them using buckets.

    What are your thoughts on Mosso’s upcoming Cloud FIles service and the limelight CDN integration?

  2. Good stuff, but I must say that if you are going to be using S3 as a site file host, it might be worth looking at the lower latency of Amazon CloudFront (S3 on ‘roids) http://paulstamatiou.com/2008/12/08/how-to-getting-started-with-amazon-cloudfront

    • Derek says:

      Good stuff writing that introduction to CloudFront. Linked in the post above for others to find. Might as well add a CDN into the mix.

  3. Andy says:

    if working with Amazon S3 on Windows try CloudBerry Explorer for Amazon S3 FREEWARE. http://cloudberrylab.com/

  4. [...] Amazon S3, CNAME record, Panic’s Transmit, and WordPress – Derek Punsalan – 5ThirtyOne Amazon Web Services Simple Storage Service (S3) is the solution for anyone wishing to store or deliver massive amounts of data without eating up precious bandwidth on their own server. Amazon S3 works great for your computer and web hosting needs. Getting started with Amazon S3 [...]

  5. This is great information, thanks for posting. I just recently started exploring S3 and simply uploaded a couple of files, a pdf and an image file. I had a couple friends test it to make sure they could see the files, and then looked at my S3 account. I had already been charged .05 cents.

    I’m wondering what the costs would be if I hosted an entire site? Would it be way more expensive that my current 3.99 on a shared host?

    Opinions or real world hosting experience on S3?