[agent] Don't fetch network info for manual networks. Fixes #46679321

- For manual networks we've the network info at the apply spec, so
we don't need to fetch the current network info.
- Moved get network info to the common Util class.