Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion manifests/mod/suphp.pp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
class apache::mod::suphp (
) {
if ($facts['os']['name'] == 'Ubuntu' and versioncmp($facts['os']['release']['major'], '15.10') >= 0) or
($facts['os']['name'] == 'Debian' and versioncmp($::operatingsystemrelease, '8') >= 0) {
$facts['os']['family'] == 'Debian' {
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I now reread this and this looks like a bad rebase from my side. This also drops Ubuntu < 15.10 support here.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

#2193 should fix that.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you @ekohl for the fixes.

fail("suphp was declared EOL by it's creators as of 2013 and so is no longer supported on Ubuntu 15.10/Debian 8 and above. Please use php-fpm")
}
include apache
Expand Down
10 changes: 4 additions & 6 deletions manifests/mpm.pp
Original file line number Diff line number Diff line change
Expand Up @@ -85,10 +85,8 @@
}

if $mpm == 'itk' {
if ( ( $::operatingsystem == 'Ubuntu' ) or ( ($::operatingsystem == 'Debian') and ( versioncmp($::operatingsystemrelease, '8.0.0') >= 0 ) ) ) {
include apache::mpm::disable_mpm_event
include apache::mpm::disable_mpm_worker
}
include apache::mpm::disable_mpm_event
include apache::mpm::disable_mpm_worker

package { 'libapache2-mpm-itk':
ensure => present,
Expand All @@ -100,14 +98,14 @@
}

if $mpm == 'prefork' {
if ( ( $::operatingsystem == 'Ubuntu' and versioncmp($::operatingsystemrelease,'18.04') >= 0 ) or ( $::operatingsystem == 'Debian' and versioncmp($::operatingsystemrelease, '8.0.0') >= 0 ) ) {
if ( ( $::operatingsystem == 'Ubuntu' and versioncmp($::operatingsystemrelease,'18.04') >= 0 ) or $::operatingsystem == 'Debian' ) {
include apache::mpm::disable_mpm_event
include apache::mpm::disable_mpm_worker
}
}

if $mpm == 'worker' {
if ( ( $::operatingsystem == 'Ubuntu' and versioncmp($::operatingsystemrelease,'18.04') >= 0 ) or ( $::operatingsystem == 'Debian' and versioncmp($::operatingsystemrelease, '8.0.0') >= 0 ) ) {
if ( ( $::operatingsystem == 'Ubuntu' and versioncmp($::operatingsystemrelease,'18.04') >= 0 ) or $::operatingsystem == 'Debian' ) {
include apache::mpm::disable_mpm_event
include apache::mpm::disable_mpm_prefork
}
Expand Down
30 changes: 7 additions & 23 deletions manifests/params.pp
Original file line number Diff line number Diff line change
Expand Up @@ -459,12 +459,11 @@
'xsendfile' => 'libapache2-mod-xsendfile',
}
}

$error_log = 'error.log'
$scriptalias = '/usr/lib/cgi-bin'
$access_log_file = 'access.log'
if $::osfamily == 'Debian' and versioncmp($::operatingsystemrelease, '8') < 0 {
$shib2_lib = 'mod_shib_22.so'
} elsif ($::operatingsystem == 'Ubuntu' and versioncmp($::operatingsystemrelease, '19.04') < 0) or ($::operatingsystem == 'Debian' and versioncmp($::operatingsystemrelease, '10') < 0) {
if ($::operatingsystem == 'Ubuntu' and versioncmp($::operatingsystemrelease, '19.04') < 0) or ($::operatingsystem == 'Debian' and versioncmp($::operatingsystemrelease, '10') < 0) {
$shib2_lib = 'mod_shib2.so'
} else {
$shib2_lib = 'mod_shib.so'
Expand All @@ -480,11 +479,7 @@
$fastcgi_lib_path = '/var/lib/apache2/fastcgi'
$mime_support_package = 'mime-support'
$mime_types_config = '/etc/mime.types'
if ($::operatingsystem == 'Ubuntu' and versioncmp($::operatingsystemrelease, '13.10') >= 0) or ($::operatingsystem == 'Debian' and versioncmp($::operatingsystemrelease, '8') >= 0) {
$docroot = '/var/www/html'
} else {
$docroot = '/var/www'
}
$docroot = '/var/www/html'
$cas_cookie_path = '/var/cache/apache2/mod_auth_cas/'
$mellon_lock_file = undef
$mellon_cache_size = undef
Expand Down Expand Up @@ -544,28 +539,17 @@
}
$alias_icons_path = '/usr/share/apache2/icons'
$error_documents_path = '/usr/share/apache2/error'
if ($::operatingsystem == 'Ubuntu' and versioncmp($::operatingsystemrelease, '13.10') >= 0) or ($::operatingsystem == 'Debian' and versioncmp($::operatingsystemrelease, '8') >= 0) {
$dev_packages = ['libaprutil1-dev', 'libapr1-dev', 'apache2-dev']
} else {
$dev_packages = ['libaprutil1-dev', 'libapr1-dev', 'apache2-prefork-dev']
}
$dev_packages = ['libaprutil1-dev', 'libapr1-dev', 'apache2-dev']

#
# Passenger-specific settings
#

$passenger_conf_file = 'passenger.conf'
$passenger_conf_package_file = undef

if ($::operatingsystem == 'Ubuntu' and versioncmp($::operatingsystemrelease, '14.04') < 0) or ($::operatingsystem == 'Debian' and versioncmp($::operatingsystemrelease, '8') < 0) {
$passenger_root = '/usr'
$passenger_ruby = '/usr/bin/ruby'
$passenger_default_ruby = undef
} else {
$passenger_root = '/usr/lib/ruby/vendor_ruby/phusion_passenger/locations.ini'
$passenger_ruby = undef
$passenger_default_ruby = '/usr/bin/ruby'
}
$passenger_root = '/usr/lib/ruby/vendor_ruby/phusion_passenger/locations.ini'
$passenger_ruby = undef
$passenger_default_ruby = '/usr/bin/ruby'
$wsgi_socket_prefix = undef
} elsif $::osfamily == 'FreeBSD' {
$user = 'www'
Expand Down
8 changes: 1 addition & 7 deletions manifests/version.pp
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,7 @@
}
}
'Debian': {
if $::operatingsystem == 'Ubuntu' and versioncmp($facts['operatingsystemmajrelease'], '13.10') >= 0 {
$default = '2.4'
} elsif $::operatingsystem == 'Debian' and versioncmp($facts['operatingsystemmajrelease'], '8') >= 0 {
$default = '2.4'
} else {
$default = '2.2'
}
$default = '2.4'
}
'FreeBSD': {
$default = '2.4'
Expand Down
8 changes: 1 addition & 7 deletions spec/spec_helper_acceptance_local.rb
Original file line number Diff line number Diff line change
Expand Up @@ -133,13 +133,7 @@ def apache_settings_hash
apache['error_log'] = 'error.log'
apache['suphp_handler'] = 'x-httpd-php'
apache['suphp_configpath'] = '/etc/php5/apache2'
apache['version'] = if osfamily == 'ubuntu' && operatingsystemrelease >= 13.10
'2.4'
elsif osfamily == 'debian' && operatingsystemrelease >= 8.0
'2.4'
else
'2.2'
end
apache['version'] = '2.4'
apache['mod_ssl_dir'] = apache['mod_dir']
when 'freebsd'
apache['httpd_dir'] = '/usr/local/etc/apache24'
Expand Down