John Brown (1800-1859) is, of course, the famed American abolitionist. The original tune comes from the earlier camp meeting hymn "Say, Brothers, Will You Meet Us" before emerging as the rather coarse march "John Brown's Body". The tune became the basis for Julia Ward Howe's "The Battle Hymn of the Republic" in November, 1961.
Many popular marches were converted to capstan or windlass songs, sometimes with the original words, and sometimes reinterpreted. The accompanying ship labor typically invoked a slower pace than would be heard on shore. John Brown's Body was one of the most recognizable and familiar of this category, and Doerflinger's words are taken from the singing of Richard Maitland in New York. Other shanty versions show up in a variety of collections.
Doerflinger borrows the line "John Brown's wife drinks whiskey in her tea!" from Bill Adams, Ships and Women (1938).