Idiom for being forced to dig your own grave?
Solution 1:
rub salt in the wound to make a difficult situation even worse for someone
In speech I have often heard/used the shortened form 'rub(s) it in'.
As if being laid off wasn't bad enough, to rub it in [rub salt into the wound] management required us to train our replacements.
Solution 2:
It's a dilemma, which in general means a choice between two unpleasant alternatives. In this case, you gain money but lose your pride, or keep your pride but lose money. It could be seen as a Hobson's choice: take the deal or get nothing. Idioms include between a rock and a hard place, damned if you do and damned if you don't.