example42 / puppet-php

A puppet module for php. According to Example42 NextGen spec.
Other
45 stars 62 forks source link

Still trouble setting the new PHP configuration folders #45

Open jimmykane opened 10 years ago

jimmykane commented 10 years ago

Still having trouble configuring PHP new config location

If setting an ini then the above solution fails due to ini.pp :

# = Define: php::ini
#
define php::ini (
    $value       = '',
    $template    = 'extra-ini.erb',
    $target      = 'extra.ini',
    $service     = $php::service,
    $config_dir  = $php::config_dir
) {

  include php

  file { "${config_dir}/conf.d/${target}":
    ensure  => 'present',
    content => template("php/${template}"),
    require => Package['php'],
    notify  => Service[$service],
  }

  file { "${config_dir}/cli/conf.d/${target}":
    ensure  => 'present',
    content => template("php/${template}"),
    require => Package['php'],
  }

}

As you can see setting the above config to apache2 will excpect for cli to be apache2/cli/conf.d/ etc

Also the conf define does not support variables as far as I can see.

alvagante commented 10 years ago

Ye, this is a bit incomplete piece of code, which doesn't manage well the php configuration mess on Debian derivatives for cli/apache/other alternative usages. Feel free to improve it if you want.

jimmykane commented 10 years ago

Checking with old versions and trying to figure out a best approach.