Skip to content

Instantly share code, notes, and snippets.

@wallyqs
Created February 15, 2021 18:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wallyqs/90e5d0c11eb50ed8eb9ed16586031390 to your computer and use it in GitHub Desktop.
Save wallyqs/90e5d0c11eb50ed8eb9ed16586031390 to your computer and use it in GitHub Desktop.
NATS Clusters + Leafnodes
system_account: sys
accounts {
sys { users = [{user: sys, pass: sys}] }
}
leaf {
port = 7422
authorization {
users = [
{ user: bsys, pass: bsys, account: sys }
]
}
}
system_account: sys
accounts {
sys { users = [{user: sys, pass: sys}] }
}
leaf {
port = 7423
authorization {
users = [
{ user: csys, pass: csys, account: sys }
]
}
}
system_account: sys
accounts {
sys { users = [{ user: sys, pass: sys}] }
}
leaf {
remotes = [
{
url = "nats://bsys:bsys@127.0.0.1:7422"
account = sys
},
{
url = "nats://csys:csys@127.0.0.1:7423"
account = sys
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment