|
etr
4.0-pre
|
Jinja2 plugin. More...
Public Member Functions | |
| def | __init__ (self, ConfigurationContext ctx) |
| def | setup (self, SetupContext ctx) |
| Render template files. More... | |
| def | teardown (self, TeardownContext ctx) |
Delete files generated during setup(). More... | |
Static Public Attributes | |
| string | config_schema |
| int | order = 1000 |
| dictionary | utils_ctx = {"get_random_port": get_random_port} |
Jinja2 plugin.
Configuration schema if rendering order is not important:
jinja2:
files:
"foo/bar.j2" : "foo/bar.config"
"baz.j2.yaml" : "$DATAROOT/config/baz.yaml"
and if rendering order is important the object jinja2["files"] may also be an array of "DESTINATION"` pairs:
jinja2:
files:
- "foo/bar.j2" : "foo/bar.config"
- "baz.j2.yaml" : "$DATAROOT/config/baz.yaml"
| def etr.plugins.jinja2.Plugin.__init__ | ( | self, | |
| ConfigurationContext | ctx | ||
| ) |
| def etr.plugins.jinja2.Plugin.setup | ( | self, | |
| SetupContext | ctx | ||
| ) |
Render template files.
| def etr.plugins.jinja2.Plugin.teardown | ( | self, | |
| TeardownContext | ctx | ||
| ) |
Delete files generated during setup().
The cleanup is oppertunistic and failures are logged but otherwise ignored to avoid cancelling any other pending plugin teardowns.
|
static |
|
static |
|
static |