The Napoleonic Wars, as Le Scaramouche says, seems to be the logical origin of the lyrics. The first known printing, as noted by the late Bruce O near the beginning of this thread, is 1825.