HiveBrain v1.2.0
Get Started
← Back to all entries
patternMinor

Is it possible to combine jinja templates in ansible like this is possible with erbs in puppet?

Submitted by: @import:stackexchange-devops··
0
Viewed 0 times
thiscombinewithlikepossibletemplatespuppetjinjaansibleerbs

Problem

It is possible to include a subtemplate in another Puppet template.


``

Solution

Yes, that is possible according to this post.

When a second jinja template was created and this was included in the base jinja it was called.

{% include "checks/subdue.j2" %}

Code Snippets

{% include "checks/subdue.j2" %}

Context

StackExchange DevOps Q#1558, answer score: 7

Revisions (0)

No revisions yet.