Skip to content
This repository has been archived by the owner on Apr 7, 2018. It is now read-only.

Commit

Permalink
Merge pull request #144 from lmn/master
Browse files Browse the repository at this point in the history
Include Support for AIX
  • Loading branch information
tas50 authored Mar 27, 2017
2 parents 79d93dc + 8d67743 commit 4246410
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 4 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ This cookbook allows you to upgrade the omnibus based Chef install package via C
- Solaris
- SLES / openSUSE
- Windows
- AIX

### Chef

Expand Down
4 changes: 2 additions & 2 deletions metadata.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
license 'Apache-2.0'
description 'Chef omnibus package updater and installer'
long_description IO.read(File.join(File.dirname(__FILE__), 'README.md'))
version '3.0.2'
version '3.0.3'

%w(amazon centos debian mac_os_x opensuse opensuseleap oracle redhat scientific solaris suse ubuntu windows).each do |os|
%w(amazon centos debian mac_os_x opensuse opensuseleap oracle redhat scientific solaris suse ubuntu windows aix).each do |os|
supports os
end

Expand Down
2 changes: 1 addition & 1 deletion recipes/default.rb
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

# fail hard if we're on an unsupported platform
# feel free to open PRs to add additional platforms
unless platform_family?('debian', 'fedora', 'mac_os_x', 'rhel', 'solaris2', 'windows', 'suse')
unless platform_family?('debian', 'fedora', 'mac_os_x', 'rhel', 'solaris2', 'windows', 'suse', 'aix')
Chef::Application.fatal! "Omnibus updater does not support the #{node['platform']} platform"
end

Expand Down
2 changes: 2 additions & 0 deletions recipes/installer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,8 @@
cd / && /usr/sbin/installer -pkg `find "/Volumes/chef_software" -name \*.pkg` -target /
hdiutil detach "/Volumes/chef_software"
EOF
when '.bff'
command "install_all_updates -cY -d #{File.join(node['omnibus_updater']['cache_dir'], File.basename(remote_path))} chef"
else
raise "Unknown package type encountered for install: #{File.extname(remote_path)}"
end
Expand Down
2 changes: 1 addition & 1 deletion recipes/old_package_cleaner.rb
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
old_pkgs =
if ::File.exist?(node['omnibus_updater']['cache_dir'])
Dir.glob(File.join(node['omnibus_updater']['cache_dir'], 'chef*')).find_all do |file|
!file.include?(node['omnibus_updater']['version'].to_s) && !file.scan(/\.(rpm|deb|msi|dmg)$/).empty?
!file.include?(node['omnibus_updater']['version'].to_s) && !file.scan(/\.(rpm|deb|msi|dmg|bff)$/).empty?
end
else
[]
Expand Down

0 comments on commit 4246410

Please sign in to comment.