{"id":17256610,"url":"https://github.com/princemaple/clusterable","last_synced_at":"2025-04-14T05:32:02.689Z","repository":{"id":57484225,"uuid":"82264061","full_name":"princemaple/clusterable","owner":"princemaple","description":"Prepare elixir/erlang nodes to be clustered","archived":false,"fork":false,"pushed_at":"2023-06-05T06:44:38.000Z","size":15,"stargazers_count":26,"open_issues_count":1,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-13T21:49:00.306Z","etag":null,"topics":["clustering","elixir","erlang","hex","libcluster"],"latest_commit_sha":null,"homepage":null,"language":"Elixir","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/princemaple.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2017-02-17T06:17:37.000Z","updated_at":"2024-02-13T04:52:52.000Z","dependencies_parsed_at":"2022-08-26T12:24:14.866Z","dependency_job_id":"96cae448-02ec-4a76-96fa-249d2794a6ef","html_url":"https://github.com/princemaple/clusterable","commit_stats":{"total_commits":22,"total_committers":1,"mean_commits":22.0,"dds":0.0,"last_synced_commit":"6f6a3061dc29e7dc7bbe60c269e11efa6376e5ad"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/princemaple%2Fclusterable","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/princemaple%2Fclusterable/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/princemaple%2Fclusterable/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/princemaple%2Fclusterable/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/princemaple","download_url":"https://codeload.github.com/princemaple/clusterable/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248826727,"owners_count":21167733,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["clustering","elixir","erlang","hex","libcluster"],"created_at":"2024-10-15T07:14:51.113Z","updated_at":"2025-04-14T05:32:02.408Z","avatar_url":"https://github.com/princemaple.png","language":"Elixir","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Clusterable\n\nHelp cluster Elixir nodes, ideal for using with `iex` and `mix`,\nnot suitable for using with releases.\n\nWith `Clusterable`, you can forget about special settings/configurations\nfor clustering. And you no longer need to start Elixir/Erlang with `--sname`\nor `--name`.\n\n## Not for releases\n\nIt's mainly for docker users (like me), and those who don't use releases.\nIt won't work in releases, as `:net_kernel` will already be started, and the cookie will already be set.\n\n## What is it good for?\n\nIt's good for clusters that don't have a fixed number of nodes,\nand you don't want to manage an orchestration script/tool that assigns names/IPs\nbefore nodes boot. i.e. it's for auto scaling clusters and lazy devs :+1:\n\n## Installation\n\nIt's [available in Hex](https://hex.pm/packages/clusterable), the package can be\ninstalled by adding `clusterable` to your list of dependencies in `mix.exs`:\n\n```elixir\ndef deps do\n  [{:clusterable, \"~\u003e 0.2\"}]\nend\n```\n\n## Example Config\n\n```elixir\nconfig :clusterable,\n  cookie: :my_cookie,\n  app_name: \"my_app\"\n```\n\n## Example Usage\n\nStart Elixir with `--erl` or `ELIXIR_ERL_OPTIONS`:\n\n```\n-proto_dist Elixir.Clusterable.EPMD.Service\n-epmd_module Elixir.Clusterable.EPMD.Client\"\n```\n\ne.g. `iex --erl \"-proto_dist ... -epmd_module ...\" -S mix`\n\nAdd Clusterable to a supervision tree as a non-permanent worker,\ni.e. `transient` or `temporary`\n\n```elixir\nworker(Clusterable, [], restart: :transient)\n```\n\nFor Elixir 1.5+, simply add `Clusterable` to your children list,\nits child_spec sets the correct restart strategy already.\n\nIf you are playing with it in IEx, you can start it manually\n\n```elixir\nClusterable.start_link\n```\n\n## Testing with Docker 1.10+\n\n- clone Clusterable project\n- in the project dir, run the commands below:\n\n```\ndocker build -t clusterable .\ndocker network create -d bridge peer\n\n# open shell 1\ndocker run --rm -it --network peer --network-alias peer clusterable\niex\u003e Clusterable.start_link\n\n# open shell 2, do the same\ndocker run --rm -it --network test --network-alias peer clusterable\niex\u003e Clusterable.start_link\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprincemaple%2Fclusterable","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fprincemaple%2Fclusterable","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprincemaple%2Fclusterable/lists"}