So you have an ubuntu image you want to save (say you just had to reinstall everything and do a custom setup and you don’t really want to go through all that again).
Follow this tutorial to get remastersys installed on ubuntu:
Use it like this:
sudo remastersys clean sudo remastersys dist
Then I copied the iso to a thumb drive, moved it to a mac computer and used dd to convert to a dmg and rewrite the usb to a live usb