If you don’t know what is a sitemap, I strongly encourage you to fill this gap in knowledge first and then get back to reading.
It seems to be clear that manual updating a sitemap can turn into a horror. Hopefully we can make the Rails do the job for us.
So, what components are we going to need to build a dynamic sitemap? Well, we are going to need a separate action (or even controller), an XML view and model methods to provide us with URL data.