I've the following Puppet manifest:
# PHP Configuration
class php {
exec { "php5enmod $module":
path => "/usr/sbin",
command => "php5enmod $module",
}
file {'/etc/php5/conf.d/upload_limits.ini':
ensure => present,
owner => root, group => root, mode => 444,
notify => [ Exec["php5enmod upload_limits"], Service["apache2"] ],
content => "post_max_size = 16M \nupload_max_filesize = 16M \n",
}
file {'/etc/php5/conf.d/memory_limits.ini':
ensure => present,
owner => root, group => root, mode => 444,
notify => [ Exec["php5enmod memory_limits"], Service["apache2"] ],
content => "memory_limit = 256M \n",
}
}
include php
How I can create exec
to use in notify
by passing the parameter dynamically? It's something that's possible, or there is another better way of doing it?
The current code gives me errors like:
Error: Could not find dependent Exec[php5enmod upload_limits] for File[/etc/php5/conf.d/upload_limits.ini]