Refactored CLI to use a single sio connection for env actions.