The problem is heat dissipation and I guarantee that you will want to use it during the day when you are on board.
If you want to use a land type air con installed inside then consider a portable air con unit that comes configured already with a hose to take the very hot air from the compressor directly outside. The trouble with dumping the heat in the cockpit locker is that it will make that locker very hot (even with the hatch open)…
I know…I tried!...
On SG I have a portable that I use when I am drydocked and my water cooled marine type cannot be used.
It is very economical and I plumb the condensate directly into the grey water line so that it can run day and night.
Usually the exhaust hose needs to run straight for about 24 inches before it can bend and then I run the hose out a porthole to get the heat directly off the boat.
Works well.
Cool Only Personal Air Conditioners at PortableAirShop.com