fix: make Jinja3 work
This commit is contained in:
parent
0a4c5ba6ed
commit
160250369b
@ -156,8 +156,10 @@ def inline_yaml(block):
|
|||||||
|
|
||||||
|
|
||||||
def JinjaEnv(template_locations=[]):
|
def JinjaEnv(template_locations=[]):
|
||||||
|
LoggingUndefined = jinja2.make_logging_undefined(logger=logger, base=Undefined)
|
||||||
jenv = jinja2.Environment(trim_blocks=True,
|
jenv = jinja2.Environment(trim_blocks=True,
|
||||||
lstrip_blocks=True,
|
lstrip_blocks=True,
|
||||||
|
undefined=LoggingUndefined,
|
||||||
extensions=['jinja2.ext.loopcontrols', 'jinja2.ext.do'])
|
extensions=['jinja2.ext.loopcontrols', 'jinja2.ext.do'])
|
||||||
|
|
||||||
if template_locations:
|
if template_locations:
|
||||||
|
@ -166,6 +166,8 @@ class Stack(object):
|
|||||||
Description: Project / Namespace this stack is part of
|
Description: Project / Namespace this stack is part of
|
||||||
"""
|
"""
|
||||||
self.cfn_template = re.sub(_res, '', self.cfn_template)
|
self.cfn_template = re.sub(_res, '', self.cfn_template)
|
||||||
|
else:
|
||||||
|
self.dependencies.add("CloudBender")
|
||||||
|
|
||||||
include = []
|
include = []
|
||||||
search_refs(self.cfn_data, include, self.mode)
|
search_refs(self.cfn_data, include, self.mode)
|
||||||
|
Loading…
Reference in New Issue
Block a user