If you are looking for a small server rack option, there do exist 10" server rack enclosures. You won't fit any standard 19" rack stuff, but it's a nice solution if you only want ISP modem, small switch, and a mini pc. example
As someone else mentioned, not advised to keep electrics near your water heater.
Yes, 10 inch half racks are a thing.
like others have said, 3d printing is your friend.
for those of you that have money as a friend, amazon sells one. https://smile.amazon.com/KENUCO-Panels-Shelves-Active-Components/dp/B07QHY8T14/
With all those short width devices, you might be better off with a non-standard width rack-
KENUCO SOHO Mini 10'' Rack for 10'' Patch Panels, Shelves, SOHO Active Components | Fan Not Included | NOT for 19'' Rack | 6U https://smile.amazon.com/dp/B07QHY8T14/ref=cm_sw_r_apan_glt_i_Q5C00DRB4TQG46RRN0ZC
Fair enough.
KENUCO SOHO Mini 10'' Rack with Fan for 10'' Patch Panels, Shelves, SOHO Active Components | NOT for 19'' Rack | 6U https://smile.amazon.com/dp/B07QHY8T14/ref=cm_sw_r_cp_api_glt_fabc_G4GX8WSJS4X46FTW7T73?_encoding=UTF8&psc=1