Set _SERVER['REMOTE_ADDR'] in cli mode

Bug: 66588
Change-Id: I6370fb81f550c5c792e0dd61c362685a4db3ef4c
Merge "Set _SERVER['REMOTE_ADDR'] in cli mode"