Puppet Class: php::params

Inherited by:
php
Defined in:
manifests/params.pp

Overview

Class: php::params

This class defines default parameters used by the main module class php Operating Systems differences in names and paths are addressed here

Variables

Refer to php class for the variables defined here.

Usage

This class is not intended to be used directly. It may be imported or inherited by other classes



15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
# File 'manifests/params.pp', line 15

class php::params {

  $package_devel = $::operatingsystem ? {
    /(?i:Ubuntu|Debian|Mint)/ => 'php5-dev',
    /(?i:SLES|OpenSuSe)/      => 'php5-devel',
    default                   => 'php-devel',
  }

  $package_pear = $::operatingsystem ? {
    /(?i:Ubuntu|Debian|Mint)/ => 'php-pear',
    /(?i:SLES|OpenSuSe)/      => 'php5-pear',
    default                   => 'php-pear',
  }

  ### Application related parameters
  $module_prefix = $::operatingsystem ? {
    /(?i:Ubuntu|Debian|Mint|SLES|OpenSuSE)/ => 'php5-',
    default                                 => 'php-',
  }

  $pear_module_prefix = $::operatingsystem ? {
    /(?i:Ubuntu|Debian|Mint)/             => 'php-',
    /(?i:SLES|OpenSuSe)/                  => 'php5-pear-',
    /(?i:CentOS|RedHat|Scientific|Linux)/ => 'php-pear-',
    default                               => 'pear-',
  }

  $package = $::operatingsystem ? {
    /(?i:Ubuntu|Debian|Mint)/ => 'php5',
    /(?i:SLES|OpenSuSE)/      => [ 'php5','apache2-mod_php5'],
    default                   => 'php',
  }

  # Here it's not the php service script name but
  # web service name like apache2, nginx, etc.
  $service = $::operatingsystem ? {
    /(?i:Ubuntu|Debian|Mint|SLES|OpenSuSE)/ => 'apache2',
    default                                 => 'httpd',
  }

  $config_dir = $::operatingsystem ? {
    /(?i:Ubuntu|Debian|Mint|SLES|OpenSuSE)/ => '/etc/php5',
    default                                   => '/etc/php.d',
  }

  $config_file = $::operatingsystem ? {
    /(?i:Ubuntu|Debian|Mint|SLES|OpenSuSE)/ => '/etc/php5/apache2/php.ini',
    default                                 => '/etc/php.ini',
  }

  $config_file_mode = $::operatingsystem ? {
    default => '0644',
  }

  $config_file_owner = $::operatingsystem ? {
    default => 'root',
  }

  $config_file_group = $::operatingsystem ? {
    default => 'root',
  }

  $data_dir = $::operatingsystem ? {
    default => '',
  }

  $log_dir = $::operatingsystem ? {
    default => '',
  }

  $log_file = $::operatingsystem ? {
    default => '',
  }

  # General Settings
  $my_class = ''
  $source = ''
  $source_dir = ''
  $source_dir_purge = false
  $augeas = false
  $template = ''
  $options = ''
  $version = 'present'
  $service_autorestart = true
  $absent = false
  $install_options = []

  ### General module variables that can have a site or per module default
  $puppi = false
  $puppi_helper = 'standard'
  $debug = false
  $audit_only = false

}