Check with your airport (which may mean going there ahead of time and scouting, getting anyone on the phone is often difficult), but most airports have someone from TSA near the main checkin desks for those people who want to insist on having their luggage inspected in their presence. Some airports require that all luggage be searched in the passengers' presence, it depends.
If you have TSA look at the bag before it is checked, they will hand it directly to the ticket agent; you may not touch it once they complete the search. The ticket agent would then be able to tape it up for you before it goes to the bag room. Most coolers do not have secure-enough lids to go through automated baggage machinery without some kind of tape on them.
It should go without saying that everything you put in the cooler should be in factory-sealed containers. Anything hand-wrapped will probably have the inspectors insisting on opening the wrapping. Generally, the issue with food is one of density; things like stacks of chocolate bars will appear opaque on the x-ray.