How would you put out such a fire from under/inside the stacks of the containers? (and given the content of the containers with consumer goods - plastic, plastic and more plastic ... )
What are the limits on the size of a ship? Width of Panama/Suez channels? Lets say they would build by 2019 (they plan to start this year and be done by 2019) the Nicaragua canal :
Inert gas, if you can get it. I'm not sure about the legalities of Halon these days, but ordinary CO2 would work, and in compressed cylinders you can store quite a lot of it in a small space. Given that we're assuming there's burning plastic you'd hope any firefighters are using respirators already, so just flood the area with CO2, deprive the fire of oxygen and there you go. CO2 is heavier than air so would naturally fill the ship, though whether you could avoid getting oxygen to the other levels I don't know. Maybe put a big tarp over the top of the ship? :P.
This site has lots of amazing pictures if you can get past the Geocities design. Like this:
http://www.cargolaw.com/2012nightmare_bai_chay_bri.html