appengine: refactor generation of base template variables
appengine: refactor generation of base template variables

Move to a single function that is used to initialize them everywhere.

uwescience/myria-web,uwescience/myria-web,uwescience/myria-web,uwescience/myria-web