Update to detect gateway ip