Replaced index creation script with template creation script

I replaced index creation script with template creation script so now user just needs to run it once.