I believe the only restriction on food is homemade foods, precooked foods and perishable food items. As long as your prepackaged foods (that means commercially packaged, not that you canned or otherwise packaged it at home) are not already open they can be brought onboard. There is no way to "cook" or prepare foods onboard, and you may be restricted at certain ports, though not likely with pre-packaged foods. No coolers.
Another option is to do your grocery run when you get off the ship so you don't have to lug around food for the length of your cruise.
Enjoy your cruise!