Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds "kernel" package before removing "kernel-xen", so packages that rely on "kernel" won't get removed. #8

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
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
6 changes: 3 additions & 3 deletions lib/boxgrinder-build/plugins/platform/ec2/ec2-plugin.rb
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,10 @@ def execute
@log.debug "'/etc/resolv.conf' uploaded."

if (@appliance_config.os.name == 'rhel' or @appliance_config.os.name == 'centos') and @appliance_config.os.version == '5'
# Remove normal kernel
guestfs.sh("yum -y remove kernel")
# because we need to install kernel-xen package
# Install kernel-xen package
guestfs_helper.sh("yum -y install kernel-xen", :arch => @appliance_config.hardware.arch)
# Then remove normal kernel. We don't need it anymore.
guestfs.sh("yum -y remove kernel")
# and add require modules
@linux_helper.recreate_kernel_image(guestfs, ['xenblk', 'xennet'])
end
Expand Down