Those "pantry moths" are weevils, and they come in with the food you put in the pantry. Ground meal, grains (flour), rice, beans, they come in and if the product is there long enough and especially if the cupboard is warm, they hatch and spread. The eggs are there, it is a given, but with enough time, they will hatch.
Toss everything in the pantry that isn't sealed tight (and weevil free) and when you bring new flour, pasta, rice, beans, into the house, put it in the freezer for a few days before you let it defrost (before freezing I put bags of flour or anything in a paper or cardboard wrapper into plastic bags and close with a twist tie to keep condensation from turning it sticky while it thaws).
Vacuum out the cupboard, you might want to use a sponge and go over all of the surfaces with some water and orange oil. Let it dry out, then replace foods. You might want to wipe down any containers that came out of that cupboard, no matter where you put them back.Google Image Search on flour weevils