All you need is to start the respective GenServer to manage the connection. Assuming you have a repo config in repo_config variable, you might:
{:ok, pid} <- MyApp.Repo.start_link(repo_config)
This server should be started supervised, otherwise, it might crash and the connection will be lost forever. For supervising dynamically started GenServers we use DynamicSupervisor.
Also, you might use the same repo to manage different connections. In such a case, Ecto.Repo.put_dynamic_repo/1 and Ecto.Repo.get_dynamic_repo/0 are your friends.
current_pid = MyApp.Repo.get_dynamic_repo()
MyApp.Repo.put_dynamic_repo(repo_pid)
# deal with repo
MyApp.Repo.put_dynamic_repo(current_pid)
In a vast majority of cases, the first approach (multiple repos) is preferred.