Skip to content

Commit c67f531

Browse files
Merge pull request #53 from A1EF/php
Add `php-8.2` pillar
2 parents c206a1f + 5d363b8 commit c67f531

File tree

2 files changed

+143
-0
lines changed

2 files changed

+143
-0
lines changed

pillar/prod/logrotate.sls

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,16 @@ logrotate:
115115
- postrotate
116116
- /usr/lib/php/php8.1-fpm-reopenlogs
117117
- endscript
118+
php8.2-fpm:
119+
path:
120+
- /var/log/php8.2-fpm.log
121+
config:
122+
- missingok
123+
- notifempty
124+
- sharedscripts
125+
- postrotate
126+
- /usr/lib/php/php8.2-fpm-reopenlogs
127+
- endscript
118128
salt-common:
119129
path:
120130
- /var/log/salt/master

pillar/prod/php82.sls

Lines changed: 133 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,133 @@
1+
# vim: ft=yaml
2+
---
3+
php:
4+
use_external_repo: true
5+
external_repo_name: 'ondrej/php'
6+
7+
version: '8.2'
8+
lookup:
9+
pkgs:
10+
curl:
11+
- php8.2-curl
12+
- curl
13+
cli:
14+
- php8.2-cli
15+
- php8.2-common
16+
xml:
17+
- php8.2-xml
18+
soap:
19+
- php8.2-soap
20+
bcmath:
21+
- php8.2-bcmath
22+
23+
fpm:
24+
conf: /etc/php/8.2/fpm/php-fpm.conf
25+
ini: /etc/php/8.2/fpm/php.ini
26+
pools: /etc/php/8.2/fpm/pool.d
27+
service: php8.2-fpm.service
28+
29+
defaults:
30+
global:
31+
pid: /run/php/php8.2-fpm.pid
32+
33+
cli:
34+
ini: /etc/php/8.2/cli/php.ini
35+
36+
fpm:
37+
service:
38+
enabled: true
39+
opts:
40+
reload: true
41+
42+
config:
43+
ini:
44+
opts:
45+
recurse: true
46+
settings:
47+
PHP:
48+
engine: 'On'
49+
expose_php: 'Off'
50+
extension_dir: '/usr/lib/php/20220829/'
51+
conf:
52+
opts:
53+
recurse: true
54+
settings:
55+
global:
56+
pid: /run/php/php8.2-fpm.pid
57+
error_log: /var/log/php8.2-fpm.log
58+
59+
# settings for fpm-pools
60+
pools:
61+
'opensourcewebsite.org.conf':
62+
enabled: true
63+
opts:
64+
replace: true
65+
66+
settings:
67+
opensourcewebsite.org:
68+
user: opensourcewebsite.org
69+
group: opensourcewebsite.org
70+
listen: /run/php/php8.2-opensourcewebsite.org.sock
71+
listen.owner: opensourcewebsite.org
72+
listen.group: opensourcewebsite.org
73+
listen.mode: '0660'
74+
pm: dynamic
75+
pm.max_children: 5
76+
pm.start_servers: 2
77+
pm.min_spare_servers: 2
78+
pm.max_spare_servers: 5
79+
slowlog: /www/opensourcewebsite.org/logs/slow.log
80+
request_slowlog_timeout: 5s
81+
'php_admin_value[memory_limit]': 4096M
82+
83+
'www.conf':
84+
enabled: true
85+
opts:
86+
replace: true
87+
88+
settings:
89+
www:
90+
user: www-data
91+
group: www-data
92+
listen: /run/php/php8.2-fpm.sock
93+
listen.owner: www-data
94+
listen.group: www-data
95+
listen.mode: '0660'
96+
pm: dynamic
97+
pm.max_children: 5
98+
pm.start_servers: 2
99+
pm.min_spare_servers: 2
100+
pm.max_spare_servers: 5
101+
slowlog: /var/log/php8.2-fpm.slow.log
102+
request_slowlog_timeout: 5s
103+
'php_admin_value[memory_limit]': 128M
104+
105+
# php-cli settings
106+
cli:
107+
ini:
108+
opts:
109+
replace: false
110+
settings:
111+
PHP:
112+
engine: 'On'
113+
expose_php: 'Off'
114+
115+
# global php.ini settings
116+
ini:
117+
defaults:
118+
PHP:
119+
engine: 'On'
120+
output_buffering: 4096
121+
disable_functions:
122+
- pcntl_alarm
123+
- pcntl_fork
124+
- pcntl_wait
125+
post_max_size: '210M'
126+
upload_max_filesize: '200M'
127+
max_execution_time: 360
128+
max_input_time: 360
129+
default_socket_timeout: 360
130+
'CLI Server':
131+
cli_server_color: 'On'
132+
'Date':
133+
'date.timezone': 'UTC'

0 commit comments

Comments
 (0)