Commit ae4de0f6551995b0c264450194a763b820cd0909

Authored by Earth Ugat
1 parent 6de3f506

Version 0.5.4. Fix bug in attribute wrapping.

1 --- 1 ---
2 driver: 2 driver:
3 name: ec2 3 name: ec2
4 - aws_ssh_key_id: cfe_stg_20160222  
5 security_group_ids: ["sg-7f6fda18"] 4 security_group_ids: ["sg-7f6fda18"]
6 region: us-west-2 5 region: us-west-2
7 availability_zone: b 6 availability_zone: b
@@ -17,10 +16,10 @@ provisioner: @@ -17,10 +16,10 @@ provisioner:
17 platforms: 16 platforms:
18 - name: ubuntu-14.04 17 - name: ubuntu-14.04
19 driver: 18 driver:
20 - image_id: ami-50946030 19 + image_id: ami-xxx
21 transport: 20 transport:
22 username: ubuntu 21 username: ubuntu
23 - ssh_key: ~/.ssh/cfe_stg_20160222.pem 22 + ssh_key: ~/.ssh/xxx.pem
24 23
25 suites: 24 suites:
26 - name: default 25 - name: default
  1 +## 0.5.4 - 2017-02-13
  2 +### Fixed
  3 +- Fix wrapped attribute bug for certain php-fpm values when PHP version is 5.6.
  4 +
1 ## 0.5.3 - 2017-01-13 5 ## 0.5.3 - 2017-01-13
2 ### Fixed 6 ### Fixed
3 - Fix misplaced 'end' directive in wordpress config template. 7 - Fix misplaced 'end' directive in wordpress config template.
@@ -26,8 +26,8 @@ Ubuntu 14.04 @@ -26,8 +26,8 @@ Ubuntu 14.04
26 <tr> 26 <tr>
27 <td><tt>['cfe-nginx-php-fpm']['php-fpm']['exts']</tt></td> 27 <td><tt>['cfe-nginx-php-fpm']['php-fpm']['exts']</tt></td>
28 <td>Array</td> 28 <td>Array</td>
29 - <td>PHP extension packages to be installed. Without the "php5-" or "php-" prefix.</td>  
30 - <td><tt>['mysqlnd', 'cli', 'curl', 'zip']</tt></td> 29 + <td>PHP extension packages to be installed. Without the "php5-" or "php-" prefix. Use `override` to customize attribute.</td>
  30 + <td><tt>['mysqlnd', 'cli', 'curl']</tt></td>
31 </tr> 31 </tr>
32 <tr> 32 <tr>
33 <td><tt>['cfe-nginx-php-fpm']['php-fpm']['version']</tt></td> 33 <td><tt>['cfe-nginx-php-fpm']['php-fpm']['version']</tt></td>
@@ -29,12 +29,9 @@ default['cfe-nginx-php-fpm']['php-fpm']['version'] = '5.5' @@ -29,12 +29,9 @@ default['cfe-nginx-php-fpm']['php-fpm']['version'] = '5.5'
29 # the default one ('www'), which is automatically installed by php-fpm 29 # the default one ('www'), which is automatically installed by php-fpm
30 default['cfe-nginx-php-fpm']['php-fpm']['delete_pool_www'] = true 30 default['cfe-nginx-php-fpm']['php-fpm']['delete_pool_www'] = true
31 31
32 -default['cfe-nginx-php-fpm']['php-fpm']['exts'] =  
33 - if node['cfe-nginx-php-fpm']['php-fpm']['version'] == '5.6'  
34 - %w{ mysqlnd cli curl zip }  
35 - else  
36 - %w{ mysqlnd cli curl }  
37 - end 32 +# Override this attribute to enter custom extensions.
  33 +# For default values, see README file.
  34 +#override['cfe-nginx-php-fpm']['php-fpm']['exts']
38 35
39 default['cfe-nginx-php-fpm']['openssl']['dh_modulus'] = 4096 36 default['cfe-nginx-php-fpm']['openssl']['dh_modulus'] = 4096
40 37
@@ -268,17 +265,6 @@ default['php-fpm']['pools'] = [ @@ -268,17 +265,6 @@ default['php-fpm']['pools'] = [
268 } 265 }
269 ] 266 ]
270 267
271 -if node['cfe-nginx-php-fpm']['php-fpm']['version'] == '5.6'  
272 - case node['platform']  
273 - when 'ubuntu'  
274 - default['php-fpm']['conf_file'] = '/etc/php/5.6/fpm/php-fpm.conf'  
275 - default['php-fpm']['conf_dir'] = '/etc/php/5.6/fpm/conf.d'  
276 - default['php-fpm']['pool_conf_dir'] = '/etc/php/5.6/fpm/pool.d'  
277 - default['php-fpm']['package_name'] = 'php5.6-fpm'  
278 - default['php-fpm']['service_name'] = 'php5.6-fpm'  
279 - end  
280 -end  
281 -  
282 # 268 #
283 # mariadb cookbook 269 # mariadb cookbook
284 # 270 #
@@ -4,7 +4,7 @@ maintainer_email 'sysadmin@chromedia.com' @@ -4,7 +4,7 @@ maintainer_email 'sysadmin@chromedia.com'
4 license 'Apache License' 4 license 'Apache License'
5 description 'Simplifies setup of Nginx+PHP-FPM in Chromedia.' 5 description 'Simplifies setup of Nginx+PHP-FPM in Chromedia.'
6 long_description IO.read(File.join(File.dirname(__FILE__), 'README.md')) 6 long_description IO.read(File.join(File.dirname(__FILE__), 'README.md'))
7 -version '0.5.3' 7 +version '0.5.4'
8 8
9 { 9 {
10 'openssl' => '4.4.0', 10 'openssl' => '4.4.0',
@@ -31,8 +31,13 @@ node.default['php-fpm']['user'] = node['nginx']['user'] @@ -31,8 +31,13 @@ node.default['php-fpm']['user'] = node['nginx']['user']
31 node.default['php-fpm']['group'] = node['nginx']['group'] 31 node.default['php-fpm']['group'] = node['nginx']['group']
32 32
33 if node['cfe-nginx-php-fpm']['php-fpm']['version'] == '5.6' 33 if node['cfe-nginx-php-fpm']['php-fpm']['version'] == '5.6'
  34 +
  35 + node.default['cfe-nginx-php-fpm']['php-fpm']['exts'] =
  36 + %w{ mysqlnd cli curl zip }
  37 +
34 case node['platform'] 38 case node['platform']
35 when 'ubuntu' 39 when 'ubuntu'
  40 +
36 apt_repository 'ondrej-php' do 41 apt_repository 'ondrej-php' do
37 uri 'ppa:ondrej/php' 42 uri 'ppa:ondrej/php'
38 distribution node['lsb']['codename'] 43 distribution node['lsb']['codename']
@@ -40,9 +45,19 @@ if node['cfe-nginx-php-fpm']['php-fpm']['version'] == '5.6' @@ -40,9 +45,19 @@ if node['cfe-nginx-php-fpm']['php-fpm']['version'] == '5.6'
40 keyserver 'keyserver.ubuntu.com' 45 keyserver 'keyserver.ubuntu.com'
41 key 'E5267A6C' 46 key 'E5267A6C'
42 end 47 end
  48 +
  49 + node.default['php-fpm']['conf_file'] = '/etc/php/5.6/fpm/php-fpm.conf'
  50 + node.default['php-fpm']['conf_dir'] = '/etc/php/5.6/fpm/conf.d'
  51 + node.default['php-fpm']['pool_conf_dir'] = '/etc/php/5.6/fpm/pool.d'
  52 + node.default['php-fpm']['package_name'] = 'php5.6-fpm'
  53 + node.default['php-fpm']['service_name'] = 'php5.6-fpm'
43 else 54 else
44 Chef::Application.fatal!("No support for PHP5.6-FPM on #{node['platform']}") 55 Chef::Application.fatal!("No support for PHP5.6-FPM on #{node['platform']}")
45 end 56 end
  57 +else
  58 +
  59 + node.default['cfe-nginx-php-fpm']['php-fpm']['exts'] =
  60 + %w{ mysqlnd cli curl }
46 end 61 end
47 62
48 if node['php-fpm']['pools'] 63 if node['php-fpm']['pools']