We went through this with all 3 of my boys. I co slept with the oldest one because his dad was in Basic Training and we didn't have a crib in the room we were sharing where ever we lived. Sometimes at my families, sometimes at his families houses. But once we moved to our first station he was fine to return to his crib.
When DS#2 came along we co slept again cause he had always been so sick and became accustomed to sleeping on one of us. That was a mistake. He stayed in our bed for another year and a half.
With Ds#2 we just kept him in his room and made sure he had pain medication for his aches. We still co slept occassionally but for the most part he could stay in bed.