commit
06cffcdd09
8 changed files with 33 additions and 14 deletions
22
CHANGELOG.md
22
CHANGELOG.md
|
@ -1,3 +1,25 @@
|
||||||
|
##2014-10-28 - Supported Release 1.7.0
|
||||||
|
###Summary
|
||||||
|
|
||||||
|
This release includes several new features, documentation and test improvements, and a few bug fixes.
|
||||||
|
|
||||||
|
####Features
|
||||||
|
- Updated unit and acceptance tests
|
||||||
|
- Update module to work with Linux Mint
|
||||||
|
- Documentation updates
|
||||||
|
- Future parser / strict variables support
|
||||||
|
- Improved support for long GPG keys
|
||||||
|
- New parameters!
|
||||||
|
- Added `apt_update_frequency` to apt
|
||||||
|
- Added `cfg_files` and `cfg_missing` parameters to apt::force
|
||||||
|
- Added `randomsleep` to apt::unattended_upgrades
|
||||||
|
- Added `apt_update_last_success` fact
|
||||||
|
- Refactored facts for performance improvements
|
||||||
|
|
||||||
|
####Bugfixes
|
||||||
|
- Update apt::builddep to require Exec['apt_update'] instead of notifying it
|
||||||
|
- Clean up lint errors
|
||||||
|
|
||||||
##2014-08-20 - Supported Release 1.6.0
|
##2014-08-20 - Supported Release 1.6.0
|
||||||
###Summary
|
###Summary
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,7 @@ apt_package_updates = nil
|
||||||
Facter.add("apt_has_updates") do
|
Facter.add("apt_has_updates") do
|
||||||
confine :osfamily => 'Debian'
|
confine :osfamily => 'Debian'
|
||||||
if File.executable?("/usr/lib/update-notifier/apt-check")
|
if File.executable?("/usr/lib/update-notifier/apt-check")
|
||||||
apt_package_updates = Facter::Util::Resolution.exec('/usr/lib/update-notifier/apt-check 2>&1').split(';')
|
apt_package_updates = Facter::Util::Resolution.exec('/usr/lib/update-notifier/apt-check 2>/dev/null').split(';')
|
||||||
end
|
end
|
||||||
|
|
||||||
setcode do
|
setcode do
|
||||||
|
@ -13,7 +13,7 @@ end
|
||||||
Facter.add("apt_package_updates") do
|
Facter.add("apt_package_updates") do
|
||||||
confine :apt_has_updates => true
|
confine :apt_has_updates => true
|
||||||
setcode do
|
setcode do
|
||||||
packages = Facter::Util::Resolution.exec('/usr/lib/update-notifier/apt-check -p 2>&1').split("\n")
|
packages = Facter::Util::Resolution.exec('/usr/lib/update-notifier/apt-check -p 2>/dev/null').split("\n")
|
||||||
if Facter.version < '2.0.0'
|
if Facter.version < '2.0.0'
|
||||||
packages.join(',')
|
packages.join(',')
|
||||||
else
|
else
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
{
|
{
|
||||||
"name": "puppetlabs-apt",
|
"name": "puppetlabs-apt",
|
||||||
"version": "1.6.0",
|
"version": "1.7.0",
|
||||||
"author": "Puppet Labs",
|
"author": "Puppet Labs",
|
||||||
"summary": "Puppet Labs Apt Module",
|
"summary": "Puppet Labs Apt Module",
|
||||||
"license": "Apache-2.0",
|
"license": "Apache-2.0",
|
||||||
"source": "https://github.com/puppetlabs/puppetlabs-apt",
|
"source": "https://github.com/puppetlabs/puppetlabs-apt",
|
||||||
"project_page": "https://github.com/puppetlabs/puppetlabs-apt",
|
"project_page": "https://github.com/puppetlabs/puppetlabs-apt",
|
||||||
"issues_url": "https://github.com/puppetlabs/puppetlabs-apt/issues",
|
"issues_url": "https://tickets.puppetlabs.com/browse/MODULES",
|
||||||
"operatingsystem_support": [
|
"operatingsystem_support": [
|
||||||
{
|
{
|
||||||
"operatingsystem": "Debian",
|
"operatingsystem": "Debian",
|
||||||
|
@ -35,9 +35,6 @@
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"dependencies": [
|
"dependencies": [
|
||||||
{
|
{"name":"puppetlabs/stdlib","version_requirement":">= 2.2.1"}
|
||||||
"name": "puppetlabs/stdlib",
|
|
||||||
"version_requirement": ">= 2.2.1"
|
|
||||||
}
|
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
|
@ -25,8 +25,8 @@ RSpec.configure do |c|
|
||||||
# Configure all nodes in nodeset
|
# Configure all nodes in nodeset
|
||||||
c.before :suite do
|
c.before :suite do
|
||||||
# Install module and dependencies
|
# Install module and dependencies
|
||||||
puppet_module_install(:source => proj_root, :module_name => 'apt')
|
|
||||||
hosts.each do |host|
|
hosts.each do |host|
|
||||||
|
copy_module_to(host, :source => proj_root, :module_name => 'apt')
|
||||||
shell("/bin/touch #{default['puppetpath']}/hiera.yaml")
|
shell("/bin/touch #{default['puppetpath']}/hiera.yaml")
|
||||||
shell('puppet module install puppetlabs-stdlib --version 2.2.1', { :acceptable_exit_codes => [0,1] })
|
shell('puppet module install puppetlabs-stdlib --version 2.2.1', { :acceptable_exit_codes => [0,1] })
|
||||||
end
|
end
|
||||||
|
|
|
@ -26,7 +26,7 @@ describe 'apt_has_updates fact' do
|
||||||
File.stubs(:executable?) # Stub all other calls
|
File.stubs(:executable?) # Stub all other calls
|
||||||
Facter::Util::Resolution.stubs(:exec) # Catch all other calls
|
Facter::Util::Resolution.stubs(:exec) # Catch all other calls
|
||||||
File.expects(:executable?).with('/usr/lib/update-notifier/apt-check').returns true
|
File.expects(:executable?).with('/usr/lib/update-notifier/apt-check').returns true
|
||||||
Facter::Util::Resolution.expects(:exec).with('/usr/lib/update-notifier/apt-check 2>&1').returns "4;3"
|
Facter::Util::Resolution.expects(:exec).with('/usr/lib/update-notifier/apt-check 2>/dev/null').returns "4;3"
|
||||||
}
|
}
|
||||||
it { should be true }
|
it { should be true }
|
||||||
end
|
end
|
||||||
|
|
|
@ -17,8 +17,8 @@ describe 'apt_package_updates fact' do
|
||||||
File.stubs(:executable?) # Stub all other calls
|
File.stubs(:executable?) # Stub all other calls
|
||||||
Facter::Util::Resolution.stubs(:exec) # Catch all other calls
|
Facter::Util::Resolution.stubs(:exec) # Catch all other calls
|
||||||
File.expects(:executable?).with('/usr/lib/update-notifier/apt-check').returns true
|
File.expects(:executable?).with('/usr/lib/update-notifier/apt-check').returns true
|
||||||
Facter::Util::Resolution.expects(:exec).with('/usr/lib/update-notifier/apt-check 2>&1').returns "1;2"
|
Facter::Util::Resolution.expects(:exec).with('/usr/lib/update-notifier/apt-check 2>/dev/null').returns "1;2"
|
||||||
Facter::Util::Resolution.expects(:exec).with('/usr/lib/update-notifier/apt-check -p 2>&1').returns "puppet-common\nlinux-generic\nlinux-image-generic"
|
Facter::Util::Resolution.expects(:exec).with('/usr/lib/update-notifier/apt-check -p 2>/dev/null').returns "puppet-common\nlinux-generic\nlinux-image-generic"
|
||||||
}
|
}
|
||||||
it {
|
it {
|
||||||
if Facter.version < '2.0.0'
|
if Facter.version < '2.0.0'
|
||||||
|
|
|
@ -17,7 +17,7 @@ describe 'apt_security_updates fact' do
|
||||||
File.stubs(:executable?) # Stub all other calls
|
File.stubs(:executable?) # Stub all other calls
|
||||||
Facter::Util::Resolution.stubs(:exec) # Catch all other calls
|
Facter::Util::Resolution.stubs(:exec) # Catch all other calls
|
||||||
File.expects(:executable?).with('/usr/lib/update-notifier/apt-check').returns true
|
File.expects(:executable?).with('/usr/lib/update-notifier/apt-check').returns true
|
||||||
Facter::Util::Resolution.expects(:exec).with('/usr/lib/update-notifier/apt-check 2>&1').returns "14;7"
|
Facter::Util::Resolution.expects(:exec).with('/usr/lib/update-notifier/apt-check 2>/dev/null').returns "14;7"
|
||||||
}
|
}
|
||||||
it { should == 7 }
|
it { should == 7 }
|
||||||
end
|
end
|
||||||
|
|
|
@ -17,7 +17,7 @@ describe 'apt_updates fact' do
|
||||||
File.stubs(:executable?) # Stub all other calls
|
File.stubs(:executable?) # Stub all other calls
|
||||||
Facter::Util::Resolution.stubs(:exec) # Catch all other calls
|
Facter::Util::Resolution.stubs(:exec) # Catch all other calls
|
||||||
File.expects(:executable?).with('/usr/lib/update-notifier/apt-check').returns true
|
File.expects(:executable?).with('/usr/lib/update-notifier/apt-check').returns true
|
||||||
Facter::Util::Resolution.expects(:exec).with('/usr/lib/update-notifier/apt-check 2>&1').returns "14;7"
|
Facter::Util::Resolution.expects(:exec).with('/usr/lib/update-notifier/apt-check 2>/dev/null').returns "14;7"
|
||||||
}
|
}
|
||||||
it { should == 14 }
|
it { should == 14 }
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue