Of course the marriage is important to you.

Our marriages are all important to us, it's the reason why we are here, trying to get back what we had.

Your sanity is more important. Your mental, emotional & physical health is more important. Your dignity, self-respect, self-value and love for yourself are more important - these are qualities that make another person attractive to other people - when you lose these qualities, you kill the attraction between you & other people (spouse, friends, etc.)

Standing up for yourself, establishing rules & boundaries with how others will treat you in your life is never unattractive. It shows courage & strength that you are willing to stand up for yourself, it shows you value yourself and when you display that message to other (directly or indirectly), they understand that and they value that too.

Somewhere along the way I suspect you lost a few of these qualities which is why your wife went outside the marriage & cheated with other people.