I think it depends. On my side, I'm OK with a modest salary if it's stable for the next 10-20 years. I think mainframe fits perfectly. It's declining but not that fast. It's unattractive so you face little competition. It's just a hell lot hard to get in in the middle of your life.
You can get that with a regular developer job with the threat of your job being a dead end.