Looking into this more, I'm thinking cloudinit.temp_utils should probably check util.get_mount_info("/var/tmp/cloud-init") to ensure noexec is not set on the mounted filesystem when needs_exe=True. It may want to fallback to use os.join.path(Distro.usr_lib_exec, "cloud-init/clouddir) in that case as /usr/lib/cloud-init or /usr/libexec/cloud-init will be mounted with exec perms.
Looking into this more, I'm thinking cloudinit. temp_utils should probably check util.get_ mount_info( "/var/tmp/ cloud-init" ) to ensure noexec is not set on the mounted filesystem when needs_exe=True. It may want to fallback to use os.join. path(Distro. usr_lib_ exec, "cloud- init/clouddir) in that case as /usr/lib/cloud-init or /usr/libexec/ cloud-init will be mounted with exec perms.