• Stars
    star
    162
  • Rank 223,908 (Top 5 %)
  • Language
    Elixir
  • License
    MIT License
  • Created 10 months ago
  • Updated 3 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Simple DNS clustering for distributed Elixir nodes

DNSCluster

Simple DNS clustering for distributed Elixir nodes.

Installation

The package can be installed by adding dns_cluster to your list of dependencies in mix.exs:

def deps do
  [
    {:dns_cluster, "~> 0.1.1"}
  ]
end

Next, you can configure and start the cluster by adding it to your supervision tree in your application.ex:

children = [
  {Phoenix.PubSub, ...},
  {DNSCluster, query: Application.get_env(:my_app, :dns_cluster_query) || :ignore},
  MyAppWeb.Endpoint
]

If you are deploying with Elixir releases, the release must be set to support longnames and the node must be named. These can be set in your rel/env.sh.eex file:

#!/bin/sh
export RELEASE_DISTRIBUTION=name
export RELEASE_NODE="myapp@fully-qualified-host-or-ip"

By default, nodes from the same release will have the same cookie. If you want different applications or releases to connect to each other, then you must set the RELEASE_COOKIE, either in your deployment platform or inside rel/env.sh.eex:

#!/bin/sh
...
export RELEASE_COOKIE="my-app-cookie"

More Repositories

1

phoenix

Peace of mind from prototype to production
Elixir
20,545
star
2

phoenix_live_view

Rich, real-time user experiences with server-rendered HTML
Elixir
5,741
star
3

phoenix_live_dashboard

Realtime dashboard with metrics, request logging, plus storage, OS and VM insights
Elixir
1,925
star
4

phoenix_pubsub

Distributed PubSub and Presence platform for the Phoenix Framework
Elixir
611
star
5

flame

Elixir
607
star
6

phoenix_guides

User guides for the Phoenix web development framework.
499
star
7

tailwind

An installer for tailwind
Elixir
461
star
8

phoenix_ecto

Phoenix and Ecto integration with support for concurrent acceptance testing
Elixir
437
star
9

phoenix_html

Building blocks for working with HTML in Phoenix
Elixir
379
star
10

phoenix_live_reload

Provides live-reload functionality for Phoenix
Elixir
289
star
11

firenest

Elixir
271
star
12

esbuild

An installer for esbuild
Elixir
261
star
13

phoenix_pubsub_redis

The Redis PubSub adapter for the Phoenix framework
Elixir
174
star
14

vscode-phoenix

Syntax highlighting support for Phoenix templates in Visual Studio Code.
155
star
15

plds

CLI version of Phoenix LiveDashboard
Elixir
85
star
16

websock

A specification for Elixir apps to service WebSocket connections
Elixir
70
star
17

phoenix_view

View abstraction for Phoenix v1.0-v1.6
Elixir
64
star
18

tree-sitter-heex

HEEx grammer for Tree-sitter
JavaScript
48
star
19

phoenix_template

Template rendering for Phoenix
Elixir
48
star
20

ex_conf

Simple Elixir Configuration Management
Elixir
35
star
21

archives

Holds archives for released Phoenix versions
27
star
22

websock_adapter

Implementation of the WebSock specification for servers
Elixir
25
star
23

phoenix_site

CSS
13
star
24

phoenix_html_helpers

Collection of helpers to generate and manipulate HTML contents
Elixir
13
star
25

media

Phoenix Related Media
10
star
26

node_checker

Elixir
3
star