I think if you're in a position to quit your job and rest/work on something you care about, I would do it. That kind of opportunity doesn't come often, and most people will never have it. I'd say especially if you're facing chronic pain or having doctors order you to rest, you'll only regret NOT resting and prioritising your health. Capitalism continues to win when we work our entire lives away.