Restore without access to state

juju-restore/restore: restore without access to the state.

Direct access to mongo via the state port will no longer be possible shortly. This PR changes restore to use the api instead of direct state access to get machine addresses (the only reason restore previously needed direct db access).