Pārlūkot izejas kodu

Merge pull request #172 from ze42/php_ng_modules

php.ng.modules
tags/v0.34.0
Niels Abspoel pirms 5 gadiem
vecāks
revīzija
27ec4744fb
Revīzijas autora e-pasta adrese nav piesaistīta nevienam kontam
3 mainītis faili ar 39 papildinājumiem un 0 dzēšanām
  1. +7
    -0
      README.rst
  2. +23
    -0
      php/ng/modules.sls
  3. +9
    -0
      pillar.example

+ 7
- 0
README.rst Parādīt failu

@@ -502,6 +502,13 @@ Disabled on opensuse need server:php:extensions repo
Installs the php-memcached package.
Disabled on opensuse need server:php:extensions repo

``php.ng.module``
--------------------

Calls ``php.ng.<name>`` for each entry in ``php:ng:modules`` if available, or
try to install the matching packages that can be set via from
``php:ng:lookup:pkgs``

``php.ng.mongo``
--------------------


+ 23
- 0
php/ng/modules.sls Parādīt failu

@@ -0,0 +1,23 @@
{% from "php/ng/map.jinja" import php with context %}

{% set modules = salt['pillar.get']('php:ng:modules') or [] %}
{% set base_name = 'php.ng.' %}
{% set existing_states = salt['cp.list_states']() %}

{% set includes = [] %}
{% set install = [] %}

{% for module in modules %}
{% set state = base_name ~ module %}
{% if state in existing_states %}
{% do includes.append(state) %}
{% else %}
{% do install.append(module) %}
{% endif %}
{% endfor %}

include: {{ includes|json }}

{% for state in install %}
{% include "php/ng/installed.jinja" %}
{% endfor %}

+ 9
- 0
pillar.example Parādīt failu

@@ -178,6 +178,15 @@ php:
'CLI Server':
cli_server_color: 'On'

# List of modules to install via php.ng.modules
modules:
# Calls `php.ng.<name>` if available, or try to install the matching
# packages that can be set via from php:ng:lookup:pkgs
- cli
- fpm
- curl
- mysql

# When using php.ng.apache2 on FreeBSD:
# Set this to False if you're not using apache-formula
use_apache_formula: True

Notiek ielāde…
Atcelt
Saglabāt