I would be scared to death (no pun intended) if I was dying and realized my main purpose in life and what gave my life meaning was my job and work. What a poor testimony to the wisdom of such person.
Some people view their work as a calling. For others it's just a way to make money. To each their own, I think.