start_peer = fn name ->
{:ok, pid, node} = :peer.start_link(%{name: name, host: ~c"127.0.0.1", longnames: true})
:ok = :erpc.call(node, :code, :add_paths, [:code.get_path()])
{pid, node}
end
{_peer_a, a} = start_peer.(:pg_a)
{peer_b, b} = start_peer.(:pg_b)