2019-08-27 00:28:44 +02:00
|
|
|
{%- set tplroot = tpldir.split('/')[0] %}
|
|
|
|
{%- from tplroot ~ "/map.jinja" import php with context %}
|
|
|
|
{%- from tplroot ~ "/libtofs.jinja" import files_switch with context %}
|
2019-08-07 17:01:55 +02:00
|
|
|
|
2019-08-27 00:28:44 +02:00
|
|
|
{%- set state = 'apache2' %}
|
|
|
|
{%- include tplroot ~ "/installed.jinja" %}
|
2019-08-07 17:01:55 +02:00
|
|
|
|
2019-08-27 00:28:44 +02:00
|
|
|
{%- if grains['os_family'] == "FreeBSD" %}
|
2019-08-07 17:01:55 +02:00
|
|
|
{{ php.lookup.apache2.module_config }}:
|
|
|
|
file.managed:
|
2019-08-27 00:28:44 +02:00
|
|
|
- source: {{ files_switch(['mod_php.conf.jinja'],
|
|
|
|
lookup='php_apache2_module_config',
|
|
|
|
use_subpath=True
|
|
|
|
) }}
|
2019-08-07 17:01:55 +02:00
|
|
|
- template: jinja
|
2019-08-27 00:28:44 +02:00
|
|
|
{%- if salt['pillar.get']('php:use_apache_formula', True) %}
|
2019-08-07 17:01:55 +02:00
|
|
|
- makedirs: true
|
|
|
|
- require_in:
|
|
|
|
- sls: apache
|
|
|
|
- watch_in:
|
|
|
|
- module: apache-restart
|
2019-08-27 00:28:44 +02:00
|
|
|
{%- endif %} #END: use apache formula
|
|
|
|
{%- endif %} #END: os = debian
|