Hey all, I'd like to include the apache service in my php puppet module. Because when changes are made to the php.ini file, naturally you'll need to bounce apache (if thats your choice of web server) in order for changes to take effect.
Same thing with adding php modules, etc. So in my php puppet module I have this class php::configure { include apache::service if $osfamily == "RedHat" { file { "/etc/php.ini": owner => "root", group => "root", mode => 0644, source => "puppet:///modules/php/php.ini", notify => Service["apache::service"], } } } And this: class php::install { include apache::service if $osfamily == "RedHat" { case $operatingsystemmajrelease { ..... "7": { package { [ "php", "php-cli", "php-devel", "php-imap", "php-ldap", "php-mysqlnd", "php-mcrypt", "php-xml", "php-gd", "php-pgsql", "php-pdo", "php-mbstring", "php-xmlrpc", "php-process" ]: ensure => present, notify => Service["apache::service"], } .... } Yet when I try to run puppet on the client node, I'm getting this result: Could not retrieve fact='nr_java_found', resolution='<anonymous>': undefined method `start_with?' for nil:NilClass Error: Could not retrieve catalog from remote server: Error 400 on SERVER: Invalid relationship: Package[php] { notify => Service[apache::service] }, because Service[apache::service] doesn't seem to be in the catalog Warning: Not using cache on failed catalog Error: Could not retrieve catalog; skipping run So just what in the heck am I doing wrong, if I may ask??? Thanks!! Tim -- GPG me!! gpg --keyserver pool.sks-keyservers.net --recv-keys F186197B -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CAOZy0e%3DMTKT85Q8ioP3t4nPRALVwoEK_-0i6xFXjS80_OMYs%2Bg%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.