If you hosted your rails website in Heroku, you are most properly using https://github.com/kjvarga/sitemap_generator gem to dynamically generate your sitemap file.
I won’t go into the details of how to use sitemap_generator, there are many website guide you for this, just google it.
Once you got your sitemap generated and uploaded to Amazon S3 successfully, you might want to track your sitemap in Google Webmaster Tools as well.
First, add your Amazon S3 site into Google Webmaster Tools. For example, http://s3.amazonaws.com/mybucket/sitemaps
Second, verify your Amazon S3 site by copy the googleXXXXX.html file into your bucket and give the permission accordingly.
Third, go into your Amazon S3 site in Google Webmaster Tools. Navigate to Site Configuration > Sitemaps, add the sitemap located in Amazon S3 for your Rails website.
Done! That All.
Google can accept “Cross-site submissions” for your sitemap.