Having trouble getting my 3 year old to sleep

My due date is in 6 weeks... And lately my 3 year old will not sleep In his own bed the past week.. He has been sleeping in his own bed since he was 1.  I don't know if he knows something is going to happen and wants to be close to me.. But I'm exhausted and I hope we can get him to stop getting in bed with us In the middle of the night!