manage dynamic local dir for jinja templates