I bought my domain at namecheap.com. It is hosted at Linode.
Step 1 : I used Linode control panel to create a CNAME. It looks like this:
Hostname Aliases to TTL
cdn amazon-provided-id.cloudfront.net Default
www clickplan.net Default
Step 2 : Go to Amazon Cloud Front and setup a CDN distribution. I followed the instructions from this blog: http://happybearsoftware.com/use-cloudfront-and-the-rails-asset-pipeline-to-speed-up-your-app.html
Note that you should also provide alternate domain name. In my case it was cdn.clickplan.net.
Step 3 : In production.rb add :
config.action_controller.asset_host = "amazon-provided-id.cloudfront.net"