building index.html with templates