You are renting your skills to an entity that needs your skills for an agreed upon rate for a certain amount of time. If another employer offers you a better situation and your current employer doesn’t counter with a better offer you leave. The rules are simple and your employer knows how to keep you if they really want you.
Getting a job is not like joining a gang or a fraternity where you are first promised a community and good life and then the money is just a formality, but that’s what people seem to see it as. Rest assured, it should always be about the money first. Money is what I’m all about and my career isn’t any worse off for it nor have I ever had to work myself to the bone for no reason just to please the company gods.