Saltstack Official PHP Formula
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

pillar.example 6.0KB

10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183
  1. ## php.ng pillar examples
  2. php:
  3. # Use external repository instead the default (only Ubuntu family)
  4. use_external_repo: True
  5. # Set the external repository name (valid only if use_external_repo is not none)
  6. external_repo_name: 'ondrej/php'
  7. # Use Software Collections Repository offering PHP 5.4, 5.5, 5.6, 7.0 and 7.1
  8. # https://www.softwarecollections.org/en/ for more information.
  9. # SCL is only supported on RHEL and CentOS and only active when using php.ng
  10. use_scl_repo: True
  11. # Which PHP version from the SCL repos to use
  12. scl_php_version: 71
  13. # Set the MongoDB driver version. You can specify (optionally) the driver version
  14. # when you add the php.mongo formula to your execution list
  15. mongo_version: "1.5.5"
  16. ng:
  17. # this section contains mostly grain filtered data, while overrides
  18. # are possible in the pillar for unique cases, if your OS is not
  19. # represented, please consider adding it to the map.jinja for
  20. # upstream inclusion
  21. lookup:
  22. # package definitions, these can be strings, lists of strings, or
  23. # lists of dictionaries
  24. pkgs:
  25. memcached: php5-memcached
  26. # ensures both will be installed
  27. curl:
  28. - php-common
  29. - curl
  30. # a dictionary can be used in more complex cases where you want
  31. # to pass forward special arguments to the pkg.installed call
  32. # you MUST include the name argument for this to work
  33. cli:
  34. -
  35. name: php-cli
  36. fromrepo: my-specialrepo
  37. -
  38. name: php-common
  39. skip_verify: True
  40. # php-fpm os-specific settings
  41. fpm:
  42. conf: /location/of/php-fpm/config.conf
  43. ini: /location/of/php-fpm/php.ini
  44. pools: /location/of/php-fpm/pool.d
  45. service: name-of-php5-fpm-service
  46. # the default content of the php5-fpm main config file
  47. defaults:
  48. global:
  49. pid: /var/run/php5-fpm.pid
  50. # php-cli os-specific settings
  51. cli:
  52. ini: /location/of/php-cli/php.ini
  53. # php-fpm settings
  54. fpm:
  55. # settings for the php-fpm service
  56. service:
  57. # if True, enables the php-fpm service, if False disables it
  58. enabled: True
  59. # additional arguments passed forward to
  60. # service.enabled/disabled
  61. opts:
  62. reload: True
  63. # settings for the relevant php-fpm configuration files
  64. config:
  65. # options to manage the php.ini file used by php-fpm
  66. ini:
  67. # arguments passed through to file.managed
  68. opts:
  69. recurse: True
  70. # php.ini file contents that will be merged with the
  71. # defaults in php.ng.ini.defaults. See php.ng.ini.defaults for
  72. # syntax guidelines.
  73. settings:
  74. PHP:
  75. engine: 'Off'
  76. extension_dir: '/usr/lib/php/modules/'
  77. extension: [pdo_mysql.so, iconv.so, openssl.so]
  78. # options to manage the php-fpm conf file
  79. conf:
  80. # arguments passed through to file.managed
  81. opts:
  82. recurse: True
  83. # php-fpm conf file contents that will be merged with
  84. # php.ng.lookup.fpm.defaults. See php.ng.ini.defaults for
  85. # ini-style syntax guidelines.
  86. settings:
  87. global:
  88. pid: /var/run/php-fpm/special-pid.file
  89. # settings for fpm-pools
  90. pools:
  91. # defaults will apply for each pools settings and can be overwritten by pool settings
  92. defaults:
  93. user: nginx
  94. group: nginx
  95. listen: /var/run/php-fpm-default.sock
  96. # name of the pool file to be managed, this will be appended
  97. # to the path specified in php.ng.lookup.fpm.pools
  98. 'mypool.conf':
  99. # If true, the pool file will be managed, if False it will be
  100. # absent
  101. enabled: True
  102. # Overwrite the filename for ext_pillar that doesn't allow
  103. # dots in fields names.
  104. filname: my_other_name.conf
  105. # arguments passed forward to file.managed or file.absent
  106. opts:
  107. replace: False
  108. # pool file contents. See php.ng.ini.defaults for ini-style
  109. # syntax guidelines.
  110. settings:
  111. myapp:
  112. user: www-data
  113. group: www-data
  114. listen: /var/run/php5-fpm-myapp.sock
  115. listen.owner: www-data
  116. listen.group: www-data
  117. listen.mode: 0660
  118. pm: dynamic
  119. pm.max_children: 5
  120. pm.start_servers: 2
  121. pm.min_spare_servers: 1
  122. pm.max_spare_servers: 3
  123. 'php_admin_value[memory_limit]': 300M
  124. # php-cli settings
  125. cli:
  126. # settings to manage the cli's php.ini
  127. ini:
  128. # opts passed forward directly to file.managed
  129. opts:
  130. replace: False
  131. # contents of the php.ini file that are merged with defaults
  132. # from php.ng.ini.defaults. See php.ng.ini.defaults for ini-style
  133. # syntax guidelines
  134. settings:
  135. PHP:
  136. engine: 'Off'
  137. # php-xcache settings
  138. xcache:
  139. ini:
  140. opts: {}
  141. # contents of the xcache.ini file that are merged with defaults
  142. # from php.xcache.ini.defaults. See php.ng.ini.defaults for ini-style
  143. settings:
  144. xcache:
  145. xcache.size: 90M
  146. # global php.ini settings
  147. ini:
  148. # Default php.ini contents. These follow a strict format. The top-
  149. # level dict keys form ini group headings. Nested key/value
  150. # pairs represent setting=value statements. If a value is a list,
  151. # its contents will be joined by commas in final rendering.
  152. defaults:
  153. PHP:
  154. engine: on
  155. output_buffering: 4096
  156. disable_functions:
  157. - pcntl_alarm
  158. - pcntl_fork
  159. - pcntl_wait
  160. 'CLI Server':
  161. cli_server_color: 'On'
  162. # When using php.ng.apache2 on FreeBSD:
  163. # Set this to False if you're not using apache-formula
  164. use_apache_formula: True