You will be punished or rewarded according to whether you have led a virtuous or a sinful life. The source of the proverb is Galatians, v, 7: ‘Whatsoever a man soweth, that shall he also reap.’
This is religious meaning, but it has a wider application in which it means the same as: As you make your bed, so you must lie in it.