I'm 71 and I seem to remember this refrain in a few pop songs of the 60s period. Dilly, more up to date, is a slightly derogatory reference to people from the North of England.
One suggestion is that the words "dilly" "dilly" replaced those of "diddle" "diddle" which were included in the lyrics of more bawdy songs about sex and drinking, apparently, written in the 17th century.