Switch from legacy variable templating system to Jinja2 everywhere