Civil after a break up??

Hey y’all I’m looking for advice.

My SO and I broke up just recently after 8 years of being together…we just had a baby, have a three year old and I have a son from a previous partner(10). He has become a bad drinker and been unfaithful. I ended it. But how do you leave being civil? Does anyone have a good relationship with an EX? How do you do it? Child support? Did y’all go to court? I’m at the angry stage of this break up due to his actions being the reason why we are going our separate ways. How do I keep my feelings aside for the sake of our kids.