Changes to match style guide and pass puppet-lint without error
No substantive behavior changes - only spacing, line alignment, quotation, etc.
This commit is contained in:
		| @@ -14,8 +14,8 @@ | |||||||
| class apache::dev { | class apache::dev { | ||||||
|   include apache::params |   include apache::params | ||||||
|  |  | ||||||
|   package { "apache_dev_package": |   package { 'apache_dev_package': | ||||||
|     name => $apache::params::apache_dev, |     ensure => installed, | ||||||
|     ensure => installed |     name   => $apache::params::apache_dev, | ||||||
|   } |   } | ||||||
| } | } | ||||||
|   | |||||||
| @@ -16,20 +16,20 @@ class apache { | |||||||
|   include apache::params |   include apache::params | ||||||
|  |  | ||||||
|   package { 'httpd': |   package { 'httpd': | ||||||
|     name   => $apache::params::apache_name, |  | ||||||
|     ensure => installed, |     ensure => installed, | ||||||
|  |     name   => $apache::params::apache_name, | ||||||
|   } |   } | ||||||
|  |  | ||||||
|   service { 'httpd': |   service { 'httpd': | ||||||
|     name      => $apache::params::apache_name, |  | ||||||
|     ensure    => running, |     ensure    => running, | ||||||
|  |     name      => $apache::params::apache_name, | ||||||
|     enable    => true, |     enable    => true, | ||||||
|     subscribe => Package['httpd'], |     subscribe => Package['httpd'], | ||||||
|   } |   } | ||||||
|  |  | ||||||
|   file { "httpd_vdir": |   file { 'httpd_vdir': | ||||||
|     path => $apache::params::vdir, |  | ||||||
|     ensure  => directory, |     ensure  => directory, | ||||||
|  |     path    => $apache::params::vdir, | ||||||
|     recurse => true, |     recurse => true, | ||||||
|     purge   => true, |     purge   => true, | ||||||
|     notify  => Service['httpd'], |     notify  => Service['httpd'], | ||||||
|   | |||||||
| @@ -1,13 +1,13 @@ | |||||||
| class apache::mod::python { | class apache::mod::python { | ||||||
|   include apache |   include apache | ||||||
|  |  | ||||||
|   package { "mod_python_package": |   package { 'mod_python_package': | ||||||
|     name    => $apache::params::mod_python_package, |  | ||||||
|     ensure  => installed, |     ensure  => installed, | ||||||
|     require => Package["httpd"]; |     name    => $apache::params::mod_python_package, | ||||||
|  |     require => Package['httpd']; | ||||||
|   } |   } | ||||||
|  |  | ||||||
|   a2mod { "python": ensure => present; } |   a2mod { 'python': ensure => present; } | ||||||
|  |  | ||||||
| } | } | ||||||
|  |  | ||||||
|   | |||||||
| @@ -1,13 +1,13 @@ | |||||||
| class apache::mod::wsgi { | class apache::mod::wsgi { | ||||||
|   include apache |   include apache | ||||||
|  |  | ||||||
|   package { "mod_wsgi_package": |   package { 'mod_wsgi_package': | ||||||
|     name    => $apache::params::mod_wsgi_package, |  | ||||||
|     ensure  => installed, |     ensure  => installed, | ||||||
|     require => Package["httpd"]; |     name    => $apache::params::mod_wsgi_package, | ||||||
|  |     require => Package['httpd']; | ||||||
|   } |   } | ||||||
|  |  | ||||||
|   a2mod { "wsgi": ensure => present; } |   a2mod { 'wsgi': ensure => present; } | ||||||
|  |  | ||||||
| } | } | ||||||
|  |  | ||||||
|   | |||||||
| @@ -5,7 +5,8 @@ | |||||||
| # Parameters: | # Parameters: | ||||||
| # - The $user that Apache runs as | # - The $user that Apache runs as | ||||||
| # - The $group that Apache runs as | # - The $group that Apache runs as | ||||||
| # - The $apache_name is the name of the package and service on the relevant distribution | # - The $apache_name is the name of the package and service on the relevant | ||||||
|  | #   distribution | ||||||
| # - The $php_package is the name of the package that provided PHP | # - The $php_package is the name of the package that provided PHP | ||||||
| # - The $ssl_package is the name of the Apache SSL package | # - The $ssl_package is the name of the Apache SSL package | ||||||
| # - The $apache_dev is the name of the Apache development libraries package | # - The $apache_dev is the name of the Apache development libraries package | ||||||
| @@ -32,31 +33,31 @@ class apache::params { | |||||||
|  |  | ||||||
|   case $::operatingsystem { |   case $::operatingsystem { | ||||||
|     'centos', 'redhat', 'fedora', 'scientific': { |     'centos', 'redhat', 'fedora', 'scientific': { | ||||||
|        $apache_name = 'httpd' |       $apache_name = 'httpd' | ||||||
|        $php_package = 'php' |       $php_package = 'php' | ||||||
|        $mod_python_package = 'mod_python' |       $mod_python_package = 'mod_python' | ||||||
|        $mod_wsgi_package = 'mod_wsgi' |       $mod_wsgi_package = 'mod_wsgi' | ||||||
|        $ssl_package = 'mod_ssl' |       $ssl_package = 'mod_ssl' | ||||||
|        $apache_dev  = 'httpd-devel' |       $apache_dev  = 'httpd-devel' | ||||||
|        $vdir = '/etc/httpd/conf.d/' |       $vdir = '/etc/httpd/conf.d/' | ||||||
|     } |     } | ||||||
|     'ubuntu', 'debian': { |     'ubuntu', 'debian': { | ||||||
|        $apache_name = 'apache2' |       $apache_name = 'apache2' | ||||||
|        $php_package = 'libapache2-mod-php5' |       $php_package = 'libapache2-mod-php5' | ||||||
|        $mod_python_package = 'libapache2-mod-python' |       $mod_python_package = 'libapache2-mod-python' | ||||||
|        $mod_wsgi_package = 'libapache2-mod-wsgi' |       $mod_wsgi_package = 'libapache2-mod-wsgi' | ||||||
|        $ssl_package = 'apache-ssl' |       $ssl_package = 'apache-ssl' | ||||||
|        $apache_dev  = [ 'libaprutil1-dev', 'libapr1-dev', 'apache2-prefork-dev' ] |       $apache_dev  = ['libaprutil1-dev', 'libapr1-dev', 'apache2-prefork-dev'] | ||||||
|        $vdir = '/etc/apache2/sites-enabled/' |       $vdir = '/etc/apache2/sites-enabled/' | ||||||
|     } |     } | ||||||
|     default: { |     default: { | ||||||
|        $apache_name = 'apache2' |       $apache_name = 'apache2' | ||||||
|        $php_package = 'libapache2-mod-php5' |       $php_package = 'libapache2-mod-php5' | ||||||
|        $mod_python_package = 'libapache2-mod-python' |       $mod_python_package = 'libapache2-mod-python' | ||||||
|        $mod_wsgi_package = 'libapache2-mod-wsgi' |       $mod_wsgi_package = 'libapache2-mod-wsgi' | ||||||
|        $ssl_package = 'apache-ssl' |       $ssl_package = 'apache-ssl' | ||||||
|        $apache_dev  = 'apache-dev' |       $apache_dev  = 'apache-dev' | ||||||
|        $vdir = '/etc/apache2/sites-enabled/' |       $vdir = '/etc/apache2/sites-enabled/' | ||||||
|     } |     } | ||||||
|   } |   } | ||||||
| } | } | ||||||
|   | |||||||
| @@ -15,8 +15,8 @@ | |||||||
| class apache::php { | class apache::php { | ||||||
|   include apache::params |   include apache::params | ||||||
|  |  | ||||||
|   package { "apache_php_package": |   package { 'apache_php_package': | ||||||
|     name   => $apache::params::php_package, |  | ||||||
|     ensure => present, |     ensure => present, | ||||||
|  |     name   => $apache::params::php_package, | ||||||
|   } |   } | ||||||
| } | } | ||||||
|   | |||||||
| @@ -13,13 +13,13 @@ | |||||||
| # Sample Usage: | # Sample Usage: | ||||||
| # | # | ||||||
| class apache::python { | class apache::python { | ||||||
| 	include apache::params |   include apache::params | ||||||
| 	include apache |   include apache | ||||||
|  |  | ||||||
|   package { "apache_python_package": |   package { 'apache_python_package': | ||||||
|     name   => $apache::params::python_package, |  | ||||||
|     ensure => present, |     ensure => present, | ||||||
|  |     name   => $apache::params::python_package, | ||||||
|   } |   } | ||||||
| 	a2mod { "python": ensure => present, } |   a2mod { 'python': ensure => present, } | ||||||
|  |  | ||||||
| } | } | ||||||
|   | |||||||
| @@ -17,15 +17,18 @@ class apache::ssl { | |||||||
|   include apache |   include apache | ||||||
|  |  | ||||||
|   case $::operatingsystem { |   case $::operatingsystem { | ||||||
|      'centos', 'fedora', 'redhat', 'scientific': { |     'centos', 'fedora', 'redhat', 'scientific': { | ||||||
|         package { "apache_ssl_package": |       package { 'apache_ssl_package': | ||||||
|            name    => "$apache::params::ssl_package", |         ensure  => installed, | ||||||
|            ensure  => installed, |         name    => $apache::params::ssl_package, | ||||||
|            require => Package['httpd'], |         require => Package['httpd'], | ||||||
|         } |       } | ||||||
|      } |     } | ||||||
|      'ubuntu', 'debian': { |     'ubuntu', 'debian': { | ||||||
|         a2mod { "ssl": ensure => present, } |       a2mod { 'ssl': ensure => present, } | ||||||
|      } |     } | ||||||
|  |     default: { | ||||||
|  |       fail( "${::operatingsystem} not defined in apache::ssl.") | ||||||
|  |     } | ||||||
|   } |   } | ||||||
| } | } | ||||||
|   | |||||||
| @@ -8,7 +8,8 @@ | |||||||
| # - The $ssl option is set true or false to enable SSL for this Virtual Host | # - The $ssl option is set true or false to enable SSL for this Virtual Host | ||||||
| # - The $configure_firewall option is set to true or false to specify if | # - The $configure_firewall option is set to true or false to specify if | ||||||
| #   a firewall should be configured. | #   a firewall should be configured. | ||||||
| # - The $template option specifies whether to use the default template or override | # - The $template option specifies whether to use the default template or | ||||||
|  | #   override | ||||||
| # - The $priority of the site | # - The $priority of the site | ||||||
| # - The $serveraliases of the site | # - The $serveraliases of the site | ||||||
| # - The $options for the given vhost | # - The $options for the given vhost | ||||||
| @@ -70,7 +71,7 @@ define apache::vhost( | |||||||
|       content => template($template), |       content => template($template), | ||||||
|       owner   => 'root', |       owner   => 'root', | ||||||
|       group   => 'root', |       group   => 'root', | ||||||
|       mode    => '755', |       mode    => '0755', | ||||||
|       require => Package['httpd'], |       require => Package['httpd'], | ||||||
|       notify  => Service['httpd'], |       notify  => Service['httpd'], | ||||||
|   } |   } | ||||||
| @@ -80,8 +81,8 @@ define apache::vhost( | |||||||
|       @firewall { |       @firewall { | ||||||
|         "0100-INPUT ACCEPT $port": |         "0100-INPUT ACCEPT $port": | ||||||
|           action => 'accept', |           action => 'accept', | ||||||
|           dport => "$port", |           dport  => '$port', | ||||||
|           proto => 'tcp' |           proto  => 'tcp' | ||||||
|       } |       } | ||||||
|     } |     } | ||||||
|   } |   } | ||||||
|   | |||||||
| @@ -22,7 +22,7 @@ define apache::vhost::proxy ( | |||||||
|     $port, |     $port, | ||||||
|     $dest, |     $dest, | ||||||
|     $priority      = '10', |     $priority      = '10', | ||||||
|     $template      = "apache/vhost-proxy.conf.erb", |     $template      = 'apache/vhost-proxy.conf.erb', | ||||||
|     $servername    = '', |     $servername    = '', | ||||||
|     $serveraliases = '', |     $serveraliases = '', | ||||||
|     $ssl           = false, |     $ssl           = false, | ||||||
| @@ -44,7 +44,7 @@ define apache::vhost::proxy ( | |||||||
|     content => template($template), |     content => template($template), | ||||||
|     owner   => 'root', |     owner   => 'root', | ||||||
|     group   => 'root', |     group   => 'root', | ||||||
|     mode    => '755', |     mode    => '0755', | ||||||
|     require => Package['httpd'], |     require => Package['httpd'], | ||||||
|     notify  => Service['httpd'], |     notify  => Service['httpd'], | ||||||
|   } |   } | ||||||
|   | |||||||
| @@ -1,6 +1,7 @@ | |||||||
| # Define: apache::vhost::redirect | # Define: apache::vhost::redirect | ||||||
| # | # | ||||||
| # This class will create a vhost that does nothing more than redirect to a given location | # This class will create a vhost that does nothing more than redirect to a | ||||||
|  | # given location | ||||||
| # | # | ||||||
| # Parameters: | # Parameters: | ||||||
| #   $port: | #   $port: | ||||||
| @@ -21,7 +22,7 @@ define apache::vhost::redirect ( | |||||||
|     $dest, |     $dest, | ||||||
|     $priority      = '10', |     $priority      = '10', | ||||||
|     $serveraliases = '', |     $serveraliases = '', | ||||||
|     $template      = "apache/vhost-redirect.conf.erb", |     $template      = 'apache/vhost-redirect.conf.erb', | ||||||
|     $vhost_name    = '*' |     $vhost_name    = '*' | ||||||
|   ) { |   ) { | ||||||
|  |  | ||||||
| @@ -34,7 +35,7 @@ define apache::vhost::redirect ( | |||||||
|     content => template($template), |     content => template($template), | ||||||
|     owner   => 'root', |     owner   => 'root', | ||||||
|     group   => 'root', |     group   => 'root', | ||||||
|     mode    => '755', |     mode    => '0755', | ||||||
|     require => Package['httpd'], |     require => Package['httpd'], | ||||||
|     notify  => Service['httpd'], |     notify  => Service['httpd'], | ||||||
|   } |   } | ||||||
| @@ -43,7 +44,7 @@ define apache::vhost::redirect ( | |||||||
|     @firewall { |     @firewall { | ||||||
|       "0100-INPUT ACCEPT $port": |       "0100-INPUT ACCEPT $port": | ||||||
|         jump  => 'ACCEPT', |         jump  => 'ACCEPT', | ||||||
|         dport => "$port", |         dport => '$port', | ||||||
|         proto => 'tcp' |         proto => 'tcp' | ||||||
|     } |     } | ||||||
|   } |   } | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Eric Shamow
					Eric Shamow