|
- # -*- coding: utf-8 -*-
- # vim: ft=jinja
-
- {%- import_yaml "logrotate/defaults.yaml" as default_settings %}
- {%- import_yaml "logrotate/osfamilymap.yaml" as osfamilymap %}
- {%- import_yaml "logrotate/osmap.yaml" as osmap %}
-
- {#- Retrieve the config dict only once #}
- {%- set _config = salt['config.get']('logrotate', default={}) %}
- {%- set defaults = salt['grains.filter_by'](
- default_settings,
- default='logrotate',
- merge=salt['grains.filter_by'](
- osfamilymap,
- grain='os_family',
- merge=salt['grains.filter_by'](
- osmap,
- grain='os',
- merge=salt['grains.filter_by'](
- _config,
- default='lookup'
- )
- )
- )
- )
- %}
-
- {%- set logrotate = defaults %}
|