Trying not to put on to much weight....

I'm 29 weeks so I have a little over 2 and half months left till my due date. Well at the start of my pregnancy I was 238 When I was 12 weeks I lost weight an was 226 which my doctor said was fine. Well now being 29 weeks I'm 245 I couldn't be more upset with myself and it sucks cuz I know I'll only put on more as the next few weeks go by. How do I get over it not care so much about how big I get? It bothers me a lot cuz this is the biggest I have ever been an I don't wanna be huge when I give birth.