Allow virt-customize to work on Ubuntu hosts as regular user

Ensure /boot/vmlinuz file can be read from regular users

Change-Id: I40628231b9d74e9786509675a97242df717910c8
This commit is contained in:
Federico Ressi 2021-05-17 11:04:52 +02:00
parent 8e8e96d27d
commit a030e9795f
1 changed files with 9 additions and 0 deletions

View File

@ -86,6 +86,15 @@ function configure_tobiko_glance {
iniset_nonempty "${tobiko_conf_file}" glance image_dir \
"${TOBIKO_GLANCE_IMAGE_DIR}"
ensure_boot_files_permissions
}
function ensure_boot_files_permissions {
if [ -f /boot/vmlinuz ]; then
sudo chmod ugo+r /boot/vmlinuz
fi
}