Boot manjaro ISO from encrypted drive

I use ventoy nowdays, but I have these notes about making custom menus that I used a while ago, maybe you can find some use for them.

Just examples of a few iso files.
You might want to change the inird to intel instead of amd depending on your system, or maybe it should be removed since microcode is now a hook in mkinitcpio.conf, I have not tried these since.
Also, make sure you either use free or nonfree with the manjaro iso depending if you have nvidia or not.
I use non free even though I have nvidia because it boots WAY faster, but if I were to install from the iso and not just use it as a live version of manjaro, I would start it with nonfree.
ISO files are located on a separate ext4 partition with the iso files inside a directory called /miso

Create /etc/grub.d/40_custom containing:

menuentry "Manjaro-live linux66 ISO" {
    set isofile="/miso/manjaro-kde-23.1.0-231215-linux66.iso"
    #set dri="nonfree"
    set dri="free"
    set lang="en_US"
    set keytable="se"
    set timezone="Europe/Stockholm"
    search --no-floppy -f --set=root $isofile
    probe -u $root --set=abc
    set pqr="/dev/disk/by-uuid/$abc"
    loopback loop $isofile
    linux (loop)/boot/vmlinuz-x86_64 img_dev=$pqr img_loop=$isofile driver=$dri tz=$timezone lang=$lang keytable=$keytable
    initrd (loop)/boot/amd_ucode.img (loop)/boot/initramfs-x86_64.img
}

menuentry "Debian-live ISO" {
    set isofile="/miso/debian-live-12.0.0-amd64-standard.iso"
    search --no-floppy -f --set=root $isofile
    loopback loop $isofile
    linux (loop)/live/vmlinuz boot=live components splash findiso=$isofile
    initrd (loop)/live/initrd.img
}

menuentry "CloneZilla-live ISO" {
   set isofile="/miso/clonezilla-live-3.1.1-18-amd64.iso"
   search --no-floppy -f --set=root $isofile
   loopback loop $isofile
   linux (loop)/live/vmlinuz boot=live components config findiso=$isofile ip=frommedia toram=filesystem.squashfs union=overlay copytoram
   initrd (loop)/live/initrd.img
}

Then run sudo update-grub

Then again, it might be completely different since you encrypt.

This might give you some ideas of how to do it, I used this and info on other sites to achieve above configs.

Side note, DO NOT EDIT /boot/grub/custom.cfg, edit /etc/default/grub and then run sudo update grub.

Good luck!

Edit
While you are at it, maybe you want to add these too:

/etc/grub.d/91_reboot

#!/bin/sh

echo "Adding reboot option." >&2

cat << EOF
menuentry 'Reboot' --class tool --class restart --id reboot {
        reboot
}
EOF

/etc/grub.d/92_poweroff

#!/bin/sh

echo "Adding poweroff option." >&2

cat << EOF
menuentry 'Poweroff' --class tool --class shutdown --id poweroff {
        halt
}
EOF
sudo chmod +x /etc/grub.d/{91_reboot,92_poweroff}
sudo update-grub