commit
74855ff1ee
3 changed files with 11 additions and 28 deletions
|
@ -45,8 +45,9 @@ class nginx::package(
|
||||||
}
|
}
|
||||||
'suse': {
|
'suse': {
|
||||||
class { 'nginx::package::suse':
|
class { 'nginx::package::suse':
|
||||||
require => Anchor['nginx::package::begin'],
|
package_name => $package_name,
|
||||||
before => Anchor['nginx::package::end'],
|
require => Anchor['nginx::package::begin'],
|
||||||
|
before => Anchor['nginx::package::end'],
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
'archlinux': {
|
'archlinux': {
|
||||||
|
|
|
@ -15,16 +15,15 @@
|
||||||
# Sample Usage:
|
# Sample Usage:
|
||||||
#
|
#
|
||||||
# This class file is not called directly
|
# This class file is not called directly
|
||||||
class nginx::package::suse {
|
class nginx::package::suse (
|
||||||
|
$package_name = 'nginx'
|
||||||
|
) {
|
||||||
|
|
||||||
$suse_packages = [
|
if $caller_module_name != $module_name {
|
||||||
'nginx-0.8', 'apache2', 'apache2-itk', 'apache2-utils', 'gd', 'libapr1',
|
warning("${name} is deprecated as a public API of the ${module_name} module and should no longer be directly included in the manifest.")
|
||||||
'libapr-util1', 'libjpeg62', 'libpng14-14', 'libxslt', 'rubygem-daemon_controller',
|
}
|
||||||
'rubygem-fastthread', 'rubygem-file-tail', 'rubygem-passenger',
|
|
||||||
'rubygem-passenger-nginx', 'rubygem-rack', 'rubygem-rake', 'rubygem-spruz',
|
|
||||||
]
|
|
||||||
|
|
||||||
package { $suse_packages:
|
package { $package_name:
|
||||||
ensure => $nginx::package_ensure,
|
ensure => $nginx::package_ensure,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -87,24 +87,7 @@ describe 'nginx::package' do
|
||||||
shared_examples 'suse' do |operatingsystem|
|
shared_examples 'suse' do |operatingsystem|
|
||||||
let(:facts) {{ :operatingsystem => operatingsystem, :osfamily => 'Suse'}}
|
let(:facts) {{ :operatingsystem => operatingsystem, :osfamily => 'Suse'}}
|
||||||
[
|
[
|
||||||
'nginx-0.8',
|
'nginx',
|
||||||
'apache2',
|
|
||||||
'apache2-itk',
|
|
||||||
'apache2-utils',
|
|
||||||
'gd',
|
|
||||||
'libapr1',
|
|
||||||
'libapr-util1',
|
|
||||||
'libjpeg62',
|
|
||||||
'libpng14-14',
|
|
||||||
'libxslt',
|
|
||||||
'rubygem-daemon_controller',
|
|
||||||
'rubygem-fastthread',
|
|
||||||
'rubygem-file-tail',
|
|
||||||
'rubygem-passenger',
|
|
||||||
'rubygem-passenger-nginx',
|
|
||||||
'rubygem-rack',
|
|
||||||
'rubygem-rake',
|
|
||||||
'rubygem-spruz',
|
|
||||||
].each do |package|
|
].each do |package|
|
||||||
it { should contain_package("#{package}") }
|
it { should contain_package("#{package}") }
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue