From b901584f2fe2f38d68f2f6b1244fbde0827b2f79 Mon Sep 17 00:00:00 2001 From: Leandro Pereira Date: Fri, 19 Jan 2024 13:23:30 -0500 Subject: [PATCH] Update README.md --- README.md | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/README.md b/README.md index 20ea9c10..88a01f30 100644 --- a/README.md +++ b/README.md @@ -40,6 +40,26 @@ Node.connect(node) Now you should see a site listed in the admin home page. +6. (Optional) Automically connect the nodes by creating a `.iex.exs` file in the root of each repository: + +In the beacon repo: + +```elixir +{:ok, hostname} = :inet.gethostname() +node = :"admin@#{List.to_string(hostname)}" +Node.connect(node) +``` + +In the beacon_live_admin repo: + +```elixir +{:ok, hostname} = :inet.gethostname() +node = :"core@#{List.to_string(hostname)}" +Node.connect(node) +``` + +This way you don't need to manually connect the nodes as shown on step 5. + ## Looking for help with your Elixir project? DockYard logo