My country in upstate New York does all print-on-demand ballots.
There are two stations: Check-in (where the voter is identified and signs their signature, and is then given a receipt from a little Zebra printer) and Ballot Pick-up, (where the voter exchanges the receipt for a ballot fresh out of a laser printer).
I believe the laser printers are largely standard off-the-shelf models, but I never looked closely. I voted early this year, and my ballot was awkwardly large because all races were printed on one side and the two ballot measures for county term limits were on the back. I suspect there are some standardized paper sizes the Board of Elections can choose from, but that’s just a guess.
After filling out the ballot, we have electronic ballot boxes that do some kind of check before marking the ballot as cast or rejecting it. They’re all locked and security-tagged. I world hope part of the process for opening the polling site would be testing the ballot boxes, but I’ve never seen it.
TLDR: My polling place doesn’t get a box of ballots, they get the components (paper, printer, toner, voter data) that are assembled on-site, on-demand. I do not know the supply chain or validations that happen before Election Day.