Server HA Cloud Auto-Join

Nomatron is in early access. Some advanced workflows may not be covered in the public docs.

Nomatron control-plane servers form a Serf gossip cluster for high availability. Use serf.retry_join to join the cluster with static addresses, cloud auto-join, or both in one list.

Configuration

hcl
serf {
  node_name      = "nomatron-server-1"
  bind_addr      = "0.0.0.0"
  advertise_addr = "192.0.2.10"
  port           = 7946
  encrypt_key    = "<SERF_GOSSIP_KEY>" # from `nomatron keygen`; render from your secret store

  retry_join = [
    "provider=aws tag_key=nomatron-serf tag_value=production region=eu-west-1",
    "192.0.2.11:7946",
  ]

  retry_join_interval = "30s"
  retry_join_max      = 0
}
FieldDescription
retry_joinStatic host:port entries and/or go-discover provider=... strings
retry_join_intervalDelay between join attempts (default 30s)
retry_join_maxMaximum attempts; 0 retries forever

serf.join was removed. Migrate existing configs to retry_join.

Static Addresses

For fixed IPs or DNS names:

hcl
retry_join = [
  "192.0.2.11:7946",
  "192.0.2.12:7946",
]

Bare IPs receive the configured serf.port automatically.

Cloud Auto-Join

Nomatron uses the open-source go-discover library for AWS, Azure, and GCP. Only provider=aws, provider=azure, and provider=gce are accepted; any other provider string is rejected at startup.

Tag every Nomatron server instance with a shared cluster tag so peers can find each other.

AWS

hcl
retry_join = [
  "provider=aws tag_key=nomatron-serf tag_value=production region=eu-west-1",
]
  • Tag EC2 instances with nomatron-serf=production (or your chosen key/value).
  • Instance role needs ec2:DescribeInstances.

Google Cloud (GCE)

hcl
retry_join = [
  "provider=gce project_name=my-project tag_value=nomatron-production",
]
  • Label GCE instances with nomatron-production (or your chosen label value).
  • VM service account needs compute.instances.list.

Microsoft Azure

hcl
retry_join = [
  "provider=azure tag_name=nomatron-serf tag_value=production tenant_id=... client_id=... subscription_id=... secret_access_key=<AZURE_CLIENT_SECRET>",
]
  • Apply tags to the network interface, not only the VM resource.
  • Service principal needs read access to tagged VMs/NICs.
  • Do not commit the client secret. Render this retry_join entry into /etc/nomatron/nomatron.hcl at deploy time from your secret store (for example a Nomad template block backed by Vault or Nomad Variables).

Environment And CLI

  • HCL is preferred for cloud provider strings (Azure secrets often contain =).
  • NOMATRON_SERF_RETRY_JOIN — newline-separated entries, or comma-separated for simple static lists.
  • NOMATRON_SERF_RETRY_JOIN_INTERVAL, NOMATRON_SERF_RETRY_JOIN_MAX
  • --serf-retry-join, --serf-retry-join-interval, --serf-retry-join-max

Operational Requirements

  • All servers share the same Postgres database.
  • All servers use the same serf.encrypt_key when gossip encryption is enabled.
  • Set advertise_addr to the reachable private IP in cloud deployments.
  • The first server can start with an empty retry_join and bootstraps a standalone cluster until peers appear.

Verify Cluster Membership

bash
nomatron status
nomatron serf-events

See also Configuration File and Running Nomatron Server .