Kernel boot img repatch. This resource will be called if the kernel update did not update the current kernel version.
ruby_block “kernel-exec #{kernel}” do
block do
shell_out!(“kexec -l /boot/vmlinuz-#{kernel} --initrd=/boot/initramfs-#{kernel}.img --reuse-cmdline”)
end
end
The variable #(kernel} is empty on first chef-client run (converged stage), since the resources are complied before with it’s current settings. But how can i run a next action resource after the package has been installed during chef-client converge run?
Looks like it is not able to run that as a single command and so it throws such an error. All you need to do is build up the command before giving it to code or try using it like this: