Alteration of the diminutives cockie (from cock) + leekie (from leek).
cock-a-leekie (plural cock-a-leekies)