Reviewed-by: Wang Chenglong 18509160991@163.com
On Fri, Oct 23, 2020 at 10:35:46AM +0800, Xu Xijian wrote:
When run job with initramfs, we should initrd modules.cgz and headers.cgz too.
Signed-off-by: Xu Xijian xuxijian@huawei.com
src/lib/job.cr | 5 +++++ 1 file changed, 5 insertions(+)
diff --git a/src/lib/job.cr b/src/lib/job.cr index 8f5dd36..75d75e5 100644 --- a/src/lib/job.cr +++ b/src/lib/job.cr @@ -303,10 +303,15 @@ class Job temp_initrds = [] of String
osimage_dir = "#{SRV_INITRD}/osimage/#{os_dir}"
boot_dir = "#{SRV_OS}/#{os_dir}/boot" temp_initrds << "#{INITRD_HTTP_PREFIX}" + "#{JobHelper.service_path("#{osimage_dir}/current")}" temp_initrds << "#{INITRD_HTTP_PREFIX}" + "#{JobHelper.service_path("#{osimage_dir}/run-ipconfig.cgz")}"
temp_initrds << "#{OS_HTTP_PREFIX}" +
"#{JobHelper.service_path("#{boot_dir}/modules-default.cgz")}"
temp_initrds << "#{OS_HTTP_PREFIX}" +
"#{JobHelper.service_path("#{boot_dir}/headers-default.cgz")}"
temp_initrds.concat(initrd_deps.split(/ /)) unless initrd_deps.empty? temp_initrds.concat(initrd_pkg.split(/ /)) unless initrd_pkg.empty?
-- 2.23.0