Where can I place a sitemap in appengine?

I know that for a typical static file, such as the app.yaml style app.yaml , the path to the directory where the specified files are stored should be specified. For instance.

 - url: /stylesheets static_dir: stylesheets 

How do I add a sitemap for a GAE server?

+4
source share
2 answers

this is what i did for my icon as it is a static file:

 - url: /favicon.ico static_files: media/img/favicon.ico upload: media/img/favicon.ico 

xml sitemap is also a static file, so you can do the same:

 - url: /sitemap.xml static_files: my/folder/path/sitemap.xml upload: my/folder/path/sitemap.xml 

not quite sure of the download, then. but my icon did not work in the first place without it

edit: if you want a dynamic sitemap, you can follow the instructions in this link to generate them every time a sitemap page is visited

+2
source

To follow the recommendations in App Engine, I would recommend that you check out this Boilerplate http://appengine.beecoss.com

There you will find where to put the sitemap.xml file and many more files that you need. This is the best way to do this.

 - url: /(robots\.txt|humans\.txt|crossdomain\.xml|sitemap\.xml) static_files: static/\1 upload: static/(robots\.txt|humans\.txt|crossdomain\.xml|sitemap\.xml) 
+1
source

All Articles