Rigidity at the boundary for conformal structures and other Cartan geometries