add a cli flag to enable gateway selection