My mother used a propane instant hot water heater in her retirement home for over 20 before it died. Worked great, but does require some water flowing through it to work at all - crank it down too much and the thing turns off. It did let my sister shower for as long as she wanted....
I am scared of propane and only use it from the little cylinders. But propane is pretty safe if any gas leak will vent overboard, not into the hull.
The best way to get heat from the engine is to buy a hot water heater with a loop for the engine coolant. It is also a help to put in an electric circulation pump powered through a thermal switch on the hot water heater, to pump engine coolant to the hot water heater. This way you not only get hot water while the engine is running, but also until it cools off. This arrangement is common in crew boats.
1975 32' Flybridge Sedan, twin Perkins 6-354 diesels, 1:1.53 velvetdrives, 16 X 19 props. Merritt Island, Florida