OLD | NEW |
| (Empty) |
1 # Define : spawn_fcgi::php_pool | |
2 # | |
3 # Define a spawn-fcgi pool snippet for php worker. Places all pool snippets into | |
4 # /etc/spawn-fcgi, where they will be automatically loaded. | |
5 # | |
6 # Parameters : | |
7 # * ensure: typically set to "present" or "absent". | |
8 # Defaults to "present" | |
9 # * pool_name: set name of pool, which is used to identify config template | |
10 # Defaults to 'pool' | |
11 # * content: set the content of the pool snippet. | |
12 # Defaults to 'template("spawn_fcgi/pool.d/$pool_name.conf.erb")', | |
13 # Undefined loads generic 'template("spawn_fcgi/pool.d/pool.conf.erb")' | |
14 # * order: specifies the load order for this pool snippet. | |
15 # Defaults to "500" | |
16 # * ip: set the ip the fcgi pool should listen on | |
17 # Defaults to '127.0.0.1' | |
18 # * port: set the port fcgi pool should listen on | |
19 # Defaults to '9000' | |
20 # * socket: set path where to spawn unix-socket | |
21 # Only works if no ip is specified! | |
22 # * mode: set file-mode of unix-socket | |
23 # Only works when socket is specified. | |
24 # * children: set number fcgi children to spawn | |
25 # * chroot: set chroot for fcgi procs | |
26 # * user: set user to run fcgi procs with | |
27 # Defaults to 'www-data' | |
28 # * group: set group to run fcgi procs with | |
29 # Defaults to 'www-data' | |
30 # | |
31 # Sample Usage: | |
32 # spawn_fcgi::php_pool { "global": | |
33 # ensure => present, | |
34 # order => '000', | |
35 # children => '15' | |
36 # } | |
37 # | |
38 define spawn_fcgi::php_pool ( | |
39 $ensure = 'present', | |
40 $content = '', | |
41 $order = '500', | |
42 $ip = undef, | |
43 $port = '9000', | |
44 $socket = undef, | |
45 $mode = undef, | |
46 $children = undef, | |
47 $chroot = undef, | |
48 $user = 'www-data', | |
49 $group = 'www-data') { | |
50 | |
51 spawn_fcgi::pool { $name : | |
52 ensure => $ensure, | |
53 pool_name => 'php-pool', | |
54 fcgi_app => '/usr/bin/php-cgi', | |
55 content => $content, | |
56 order => $order, | |
57 ip => $ip, | |
58 port => $port, | |
59 socket => $socket, | |
60 mode => $mode, | |
61 children => $children, | |
62 chroot => $chroot, | |
63 user => $user, | |
64 group => $group | |
65 } | |
66 | |
67 } | |
OLD | NEW |