Hoping for a response from a culinary historian. I figure that given the technology and varieties of tomato available at the time, ripe tomatoes should only have been available for a month or two. Canning technology was not invented until the 19th century, and took a long time to become reliable, so how did a chef in Naples manage to supply tomatoes for pizza all year long?
It's relevant to point out that your understanding of the seasonal availability of tomatoes isn't accurate. Ripe, or at least passably ripe, tomatoes in a mediterranean climate, even with the varieties available back then, would have been present for at least 6-8 months out of the year, obviously less abundant on either end of that span.
The first Italian pizzeria, Antica Pizzeria Port’Alba, opened in Naples 1738, so we're looking at about 70 years before canning. Someone more knowledgable will have to comment regarding what they did during the months where tomatoes weren't available. Even today there are varieties of pizza without tomatoes, so that certainly would have been an option.
Prior to canning (and later freezing and rapid transportation of fresh vegetables via refrigerated train, truck and plane) people ate fresh vegetables seasonally. Throughout most of human history, when vegetables were not in season no one expected to see them at the table in their fresh forms. Quite possibly, in the 1700s Neapolitans ate pizza with tomato in season and pizza without tomato at other times and were not upset at all by this arrangement. Thomas Jefferson in the late 18th century and early 19th century made a big deal each spring when the first peas and the first strawberries came to his table and carefully recorded the dates this happened each year.
That said, people have tried over history also to devise ways to make fresh vegetables available out of season or for a longer period each year than they traditionally were. One way was practiced in and around Paris starting as early as the 1670s through the early 1900s. It involved burying 18 inches of fresh (hot and active) horse manure under a layer of soil and inside a closable glass frame called a "hot bed" in English. The heat of the decomposing manure enabled the La culture maraîchère (market gardening) to flourish in Paris in the last half of the 19th century. This made huge quantities of previously out-of-season vegetables available to Parisians throughout the winters and helped solve the problem of what to do with all the horse manure collected within the city.
I have seen no evidence a similar system was used in Naples although I am looking at a 1824 reference to "the market-gardeners at Rome and Naples." (An Encyclopaedia of Gardening: Comprising the Theory and Practice of ... John Claudius Loudon (1824), p. 494), so we absolutely know there were market gardeners in Naples by the early 19th century. If there was demand (and there evidently was), enterprising gardeners may have been working to prolong the season for fresh tomatoes.