This all goes back to the days of hot metal typesetting and letterpress printing. A galley was originally a long metal tray into which the lines of hot-metal type were placed after composition. After the galley was filled with lines of type (about 2-3 pages worth depending on the page design) it would be locked up, holding the type tight within it, then inked by hand roller and a proof pulled. This galley proof, the first proof, was commonly referred to as a galley. It would be followed after correction, by page proofs – the galley was unlocked and the lines of type corrected and made up into pages, before a similar lock-up and hand proofing of the composed pages.
So galleys over the years came to mean first proofs, and as publishers began to economize by not sending revised proof to their authors, checking them in-house against the foul galleys, the word began to be synonymous with “proofs”. Being a more romantic sounding word than just “proof”, “galley” has stuck, but has now morphed to a more specialized meaning as bound galleys – those lovely paperback books we all love to pick up at BEA.