File tree Expand file tree Collapse file tree 4 files changed +12
-10
lines changed
Expand file tree Collapse file tree 4 files changed +12
-10
lines changed Original file line number Diff line number Diff line change 11# -*- coding: utf-8 -*-
22# vim: ft=sls
33
4- {%- from " template /map.jinja" import template with context % }
5- {%- from " template /macros.jinja" import files_switch with context % }
4+ {%- from tpldir ~ " /map.jinja" import template with context % }
5+ {%- from tpldir ~ " /macros.jinja" import files_switch with context % }
66
77include:
88 - template.install
Original file line number Diff line number Diff line change 11# -*- coding: utf-8 -*-
22# vim: ft=sls
33
4- {% from " template /map.jinja" import template with context % }
4+ {%- from tpldir ~ " /map.jinja" import template with context % }
55
66template- pkg:
77 pkg.installed:
Original file line number Diff line number Diff line change 11# -*- coding: utf-8 -*-
22# vim: ft=jinja
33
4- {## Start imports as ##}
5- {% import_yaml 'template/defaults.yaml' as default_settings %}
6- {% import_yaml 'template/osfamilymap.yaml' as osfamilymap %}
7- {% import_yaml 'template/osmap.yaml' as osmap %}
8- {% import_yaml 'template/osfingermap.yaml' as osfingermap %}
4+ {#- Get the `topdir` from `tpldir` #}
5+ {% - set topdir = tpldir .split ('/' )[0] %}
6+ {#- Start imports as #}
7+ {% - import_yaml topdir ~ "/defaults.yaml" as default_settings %}
8+ {% - import_yaml topdir ~ "/osfamilymap.yaml" as osfamilymap %}
9+ {% - import_yaml topdir ~ "/osmap.yaml" as osmap %}
10+ {% - import_yaml topdir ~ "/osfingermap.yaml" as osfingermap %}
911
1012{% set defaults = salt ['grains.filter_by' ](default_settings ,
1113 default ='template' ,
1820 )
1921) %}
2022
21- {## Merge the template pillar # #}
23+ {#- Merge the template pillar #}
2224{% set template = salt ['pillar.get' ]('template' , default =defaults , merge =True ) %}
Original file line number Diff line number Diff line change 11# -*- coding: utf-8 -*-
22# vim: ft=sls
33
4- {% from " template /map.jinja" import template with context % }
4+ {%- from tpldir ~ " /map.jinja" import template with context % }
55
66include:
77 - template.config
You can’t perform that action at this time.
0 commit comments