While not an expert on Egyptian ships, I did once inquire about Dane traders and raiders diet in the Heddeby museum. They told me, that on a viking, they would mainly eat pre-prepared provisions that didn't need extra heating before consumption, as there wouldn't be a chance to light a fire aboard unless the sea was very calm. Also, they told me that often the traders did land at the coast whenever possible to keep the stock of those provisions (for example, salted fishes and butter) high, as falling below a certain amount of them would cause the traders to abort their travel.
As far as I know about ancient Egyptian ships, they had relatively few seagoing ships. As their main internal trade routes where along the Nile, there likely wasn't a need to light fires aboard on these routes.
The Phoenicians and Greeks had seagoing ships some time before the great Greek colonialisation. Yet I have no clue how they prepared provisions aboard. However, I would not rule out, that they did rely on pre-prepared provisions and cooking on shore when possible, as the shipboards were relatively comparable to viking Knarr type longships for most trading vessels: quite bulky but flat and a low seaboard. These don't generally allow much protection from wind and weather for a possible fireplace, but it could be made possible with careful stowing and a rock/clay/ceramic basin for the fire.
On the other hand, the warship reconstructions I saw (bireme & triere types) didn't seem to include a storage space large enough to operate much more than getting supplies in it, let alone indicate a dedicated kitchen, thus again leading to the conclusion of probably preprepared provisions.