php-formula/php/ini.jinja
sticky-note 8e79a3595c
feat(tofs): implementation for all file.managed
- Implementation of libtofs on ini macro, pools_config and apache2 mod_php.conf
+ Introduction of tplroot on modified files
+ `{%-` consistency when possible
2019-09-13 10:59:05 +01:00

19 lines
594 B
Django/Jinja

# -*- coding: utf-8 -*-
# vim: ft=jinja
{#- php.ini management macro. #}
{%- set tplroot = tpldir.split('/')[0] %}
{%- from tplroot ~ "/macro.jinja" import sls_block, serialize %}
{%- from tplroot ~ "/libtofs.jinja" import files_switch with context %}
{% macro php_ini(filename, tofs_lookup, opts={}, settings={}) %}
file.managed:
{{ sls_block(opts) }}
- name: {{ filename }}
- source: {{ files_switch(['php.ini'],
tofs_lookup
) }}
- template: jinja
- context:
config: {{ serialize(odict(settings)) }}
{%- endmacro -%}