2 metre range sensor question

I would use a modulated IR beam and a reflector on the other side of the door. A TSOP4038 is the right sort of sensor for that.