Commit 2244dc3d authored by Fabian Galinski's avatar Fabian Galinski 😾
Browse files

[FEATURE] Adds a setting to install additional PHP modules

parent e34156a8
......@@ -142,3 +142,11 @@ default['normal_site']['create_links'] = []
# }
# ]
default['normal_site']['create_additional_vhosts'] = []
# Example:
# [
# {
# :name => 'redis'
# }
# ]
default['normal_site']['additional_php_modules'] = []
......@@ -12,4 +12,4 @@ source_url 'https://gitlab.sgalinski.de/chef-cookbooks/normal_site'
depends 'hostsfile'
depends 'java'
depends 'line'
depends 'ubuntu_base'
\ No newline at end of file
depends 'ubuntu_base'
......@@ -296,6 +296,22 @@ if node['normal_site']['install_ioncube']
end
end
######################################
### Install additional PHP modules ###
######################################
node['normal_site']['additional_php_modules'].each do |additionalPhpModule|
package 'php' + node['ubuntu_base']['php_version'] + '-' + additionalPhpModule['name'] do
action 'upgrade'
end
execute "phpenmod " + additionalPhpModule['name']
service "php#{node['ubuntu_base']['php_version']}-fpm" do
action :restart
end
end
################################
### Setup Apache Environment ###
################################
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment