TEMPLATES = [{'BACKEND': 'django.template.backends.jinja2.Jinja2', 'DIRS':
    [os.path.join(BASE_DIR, 'templates/jinja2')], 'APP_DIRS': True,
    'OPTIONS': {'environment': 'myproject.jinja2.Environment'}}, {'BACKEND':
    'django.template.backends.django.DjangoTemplates', 'DIRS': [],
    'APP_DIRS': True, 'OPTIONS': {'context_processors': [
    'django.template.context_processors.debug',
    'django.template.context_processors.request',
    'django.contrib.auth.context_processors.auth',
    'django.contrib.messages.context_processors.messages']}}]
How to use jinja2 as a templating engine in Django 1.8