Assuming you've got the iso ready, and are familar with Qemu.
1. Mount the ISO
$ fuseiso ubuntu-24.04.1-live-server-amd64.iso iso
2. Append the relevant lines to your Qemu command line
$ qemu-system-x86_86 -serial mon:stdio -nographic -display curses -append 'console=ttyS0,115200,8n1' -kernel iso/casper/vmlinuz -initrd iso/casper/initrd
Easy peasy!

¹ Mostly Qemu