Which preposition to use with prenticeship

of Occurrences 1%

They are my seven years' 'prenticeship of woe.

on Occurrences 1%

As good men as you, and have thought it no scorn to serve their 'prenticeships on the pillory.

Which preposition to use with  prenticeship