1
- ; Start a new pool named '<%= name %> '.
1
+ ; Start a new pool named '<%= @ name %> '.
2
2
; the variable $pool can be used in any directive and will be replaced by the
3
- ; pool name ('<%= name %> ' here)
4
- [<%= name %> ]
3
+ ; pool name ('<%= @ name %> ' here)
4
+ [<%= @ name %> ]
5
5
6
6
; Per pool prefix
7
7
; It only applies on the following directives:
15
15
; Note: This directive can also be relative to the global prefix.
16
16
; Default Value: none
17
17
<% if @pool_prefix -%>
18
- prefix = <%= pool_prefix %>
18
+ prefix = <%= @ pool_prefix %>
19
19
<% end -%>
20
20
21
21
; Unix user/group of processes
22
22
; Note: The user is mandatory. If the group is not set, the default user's group
23
23
; will be used.
24
- user = <%= user %>
24
+ user = <%= @ user %>
25
25
<% if @group -%>
26
- group = <%= group %>
26
+ group = <%= @ group %>
27
27
<% end -%>
28
28
29
29
; The address on which to accept FastCGI requests.
@@ -34,39 +34,39 @@ group = <%= group %>
34
34
; specific port;
35
35
; '/path/to/unix/socket' - to listen on a unix socket.
36
36
; Note: This value is mandatory.
37
- listen = <%= listen %>
37
+ listen = <%= @ listen %>
38
38
39
39
<% if @listen_backlog -%>
40
40
; Set listen(2) backlog. A value of '-1' means unlimited.
41
41
; Default Value: 128 (-1 on FreeBSD and OpenBSD)
42
- listen.backlog = <%= listen_backlog %>
42
+ listen.backlog = <%= @ listen_backlog %>
43
43
<% end -%>
44
44
45
- <% if listen_type == 'socket' -%>
45
+ <% if @ listen_type == 'socket' -%>
46
46
; Set permissions for unix socket, if one is used. In Linux, read/write
47
47
; permissions must be set in order to allow connections from a web server. Many
48
48
; BSD-derived systems allow connections regardless of permissions.
49
49
; Default Values: user and group are set as the running user
50
50
; mode is set to 0666
51
51
<% if @socket_owner -%>
52
- listen.owner = <%= socket_owner %>
52
+ listen.owner = <%= @ socket_owner %>
53
53
<% end -%>
54
54
<% if @socket_group -%>
55
- listen.group = <%= socket_group %>
55
+ listen.group = <%= @ socket_group %>
56
56
<% end -%>
57
57
<% if @socket_mode -%>
58
- listen.mode = <%= socket_mode %>
58
+ listen.mode = <%= @ socket_mode %>
59
59
<% end -%>
60
60
<% end -%>
61
61
62
- <% if listen_type == 'tcp' and @allowed_clients -%>
62
+ <% if @ listen_type == 'tcp' and @allowed_clients -%>
63
63
; List of ipv4 addresses of FastCGI clients which are allowed to connect.
64
64
; Equivalent to the FCGI_WEB_SERVER_ADDRS environment variable in the original
65
65
; PHP FCGI (5.2.2+). Makes sense only with a tcp listening socket. Each address
66
66
; must be separated by a comma. If this value is left blank, connections will be
67
67
; accepted from any ip address.
68
68
; Default Value: any
69
- listen.allowed_clients = <%= allowed_clients %>
69
+ listen.allowed_clients = <%= @ allowed_clients %>
70
70
<% end -%>
71
71
72
72
; Choose how the process manager will control the number of child processes.
@@ -93,7 +93,7 @@ listen.allowed_clients = <%= allowed_clients %>
93
93
; pm.process_idle_timeout - The number of seconds after which
94
94
; an idle process will be killed.
95
95
; Note: This value is mandatory.
96
- pm = <%= pm %>
96
+ pm = <%= @ pm %>
97
97
98
98
; The number of child processes to be created when pm is set to 'static' and the
99
99
; maximum number of child processes when pm is set to 'dynamic' or 'ondemand'.
@@ -104,38 +104,38 @@ pm = <%= pm %>
104
104
; forget to tweak pm.* to fit your needs.
105
105
; Note: Used when pm is set to 'static', 'dynamic' or 'ondemand'
106
106
; Note: This value is mandatory.
107
- pm.max_children = <%= pm_max_children %>
107
+ pm.max_children = <%= @ pm_max_children %>
108
108
109
- <% if pm == 'dynamic' -%>
109
+ <% if @ pm == 'dynamic' -%>
110
110
; The number of child processes created on startup.
111
111
; Note: Used only when pm is set to 'dynamic'
112
112
; Default Value: min_spare_servers + (max_spare_servers - min_spare_servers) / 2
113
- pm.start_servers = <%= pm_start_servers %>
113
+ pm.start_servers = <%= @ pm_start_servers %>
114
114
115
115
; The desired minimum number of idle server processes.
116
116
; Note: Used only when pm is set to 'dynamic'
117
117
; Note: Mandatory when pm is set to 'dynamic'
118
- pm.min_spare_servers = <%= pm_min_spare_servers %>
118
+ pm.min_spare_servers = <%= @ pm_min_spare_servers %>
119
119
120
120
; The desired maximum number of idle server processes.
121
121
; Note: Used only when pm is set to 'dynamic'
122
122
; Note: Mandatory when pm is set to 'dynamic'
123
- pm.max_spare_servers = <%= pm_max_spare_servers %>
123
+ pm.max_spare_servers = <%= @ pm_max_spare_servers %>
124
124
<% end -%>
125
125
126
- <% if pm == 'ondemand' -%>
126
+ <% if @ pm == 'ondemand' -%>
127
127
; The number of seconds after which an idle process will be killed.
128
128
; Note: Used only when pm is set to 'ondemand'
129
129
; Default Value: 10s
130
- pm.process_idle_timeout = <%= pm_process_idle_timeout %>
130
+ pm.process_idle_timeout = <%= @ pm_process_idle_timeout %>
131
131
<% end -%>
132
132
133
133
<% if @pm_max_requests -%>
134
134
; The number of requests each child process should execute before respawning.
135
135
; This can be useful to work around memory leaks in 3rd party libraries. For
136
136
; endless request processing specify '0'. Equivalent to PHP_FCGI_MAX_REQUESTS.
137
137
; Default Value: 0
138
- pm.max_requests = <%= pm_max_requests %>
138
+ pm.max_requests = <%= @ pm_max_requests %>
139
139
<% end -%>
140
140
141
141
<% if @pm_status_path -%>
@@ -236,7 +236,7 @@ pm.max_requests = <%= pm_max_requests %>
236
236
; anything, but it may not be a good idea to use the .php extension or it
237
237
; may conflict with a real PHP file.
238
238
; Default Value: not set
239
- pm.status_path = <%= pm_status_path %>
239
+ pm.status_path = <%= @ pm_status_path %>
240
240
<% end -%>
241
241
242
242
<% if @ping_path -%>
@@ -250,20 +250,20 @@ pm.status_path = <%= pm_status_path %>
250
250
; anything, but it may not be a good idea to use the .php extension or it
251
251
; may conflict with a real PHP file.
252
252
; Default Value: not set
253
- ping.path = <%= ping_path %>
253
+ ping.path = <%= @ ping_path %>
254
254
255
255
<% if @ping_response -%>
256
256
; This directive may be used to customize the response of a ping request. The
257
257
; response is formatted as text/plain with a 200 response code.
258
258
; Default Value: pong
259
- ping.response = <%= ping_response %>
259
+ ping.response = <%= @ ping_response %>
260
260
<% end -%>
261
261
<% end -%>
262
262
263
263
<% if @access_log -%>
264
264
; The access log file
265
265
; Default: not set
266
- access.log = <%= access_log %>
266
+ access.log = <%= @ access_log %>
267
267
268
268
<% if @access_log_format -%>
269
269
; The access log format.
@@ -319,30 +319,30 @@ access.log = <%= access_log %>
319
319
; %u: remote user
320
320
;
321
321
; Default: "%R - %u %t \"%m %r\" %s"
322
- access.format = <%= access_log_format %>
322
+ access.format = <%= @ access_log_format %>
323
323
<% end -%>
324
324
<% end -%>
325
325
326
326
<% if @slowlog -%>
327
327
; The log file for slow requests
328
328
; Default Value: not set
329
329
; Note: slowlog is mandatory if request_slowlog_timeout is set
330
- slowlog = <%= slowlog %>
330
+ slowlog = <%= @ slowlog %>
331
331
332
332
; The timeout for serving a single request after which a PHP backtrace will be
333
333
; dumped to the 'slowlog' file. A value of '0s' means 'off'.
334
334
; Available units: s(econds)(default), m(inutes), h(ours), or d(ays)
335
335
; Default Value: 0
336
- request_slowlog_timeout = <%= slowlog_timeout %>
336
+ request_slowlog_timeout = <%= @ slowlog_timeout %>
337
337
<% end -%>
338
338
339
339
; The timeout for serving a single request after which the worker process will
340
340
; be killed. This option should be used when the 'max_execution_time' ini option
341
341
; does not stop script execution for some reason. A value of '0' means 'off'.
342
342
; Available units: s(econds)(default), m(inutes), h(ours), or d(ays)
343
343
; Default Value: 0
344
- request_terminate_timeout = <%= terminate_timeout %>
345
344
345
+ request_terminate_timeout = <%= @terminate_timeout %>
346
346
; Set open file descriptor rlimit.
347
347
; Default Value: system defined value
348
348
;rlimit_files = 1024
@@ -362,7 +362,7 @@ request_terminate_timeout = <%= terminate_timeout %>
362
362
; possible. However, all PHP paths will be relative to the chroot
363
363
; (error_log, sessions.save_path, ...).
364
364
; Default Value: not set
365
- chroot = <%= chroot %>
365
+ chroot = <%= @ chroot %>
366
366
<% end -%>
367
367
368
368
; Chdir to this directory at the start.
@@ -394,7 +394,7 @@ chdir = /
394
394
;env[TMPDIR] = /tmp
395
395
;env[TEMP] = /tmp
396
396
<% if @env_settings -%>
397
- <% env_settings.each do |env_setting| -%>
397
+ <% @ env_settings.each do |env_setting| -%>
398
398
<%= env_setting %>
399
399
<% end -%>
400
400
<% end -%>
@@ -424,7 +424,7 @@ chdir = /
424
424
;php_admin_value[error_log] = /var/log/fpm-php.www.log
425
425
;php_admin_flag[log_errors] = on
426
426
;php_admin_value[memory_limit] = 32M
427
- <% php_settings.each do |php_setting| -%>
427
+ <% @ php_settings.each do |php_setting| -%>
428
428
<%= php_setting %>
429
429
<% end -%>
430
430
<% end -%>
0 commit comments