Pink eye

My son of 2 months has a bacterial pink eye(Conjunctivitis).. how do you get bacterial pink eye?