Reference Architecture

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

A good reference architecture gives operators a deployment shape they can adapt without forcing a single rigid implementation.

For Nomatron, the key design assumptions are:

  • Nomatron servers are stateless and are designed to run behind a load balancer;
  • PostgreSQL is the durable source of truth;
  • multiple Nomatron servers coordinate through Serf;
  • private network agents connect to the server gRPC endpoint; and
  • the health endpoint can be used by load balancers to decide whether a Nomatron server instance should receive traffic.

This page starts with a cloud-agnostic baseline, then gives a practical recommendation for AWS, Azure, and Google Cloud.

Cloud-Agnostic Baseline

The cloud-agnostic production model looks like this:

  1. users reach Nomatron through a stable DNS name such as nomatron.example.com;
  2. a load balancer or ingress layer terminates TLS and forwards traffic to Nomatron servers;
  3. Nomatron servers run as a small stateless cluster, typically three nodes;
  4. all Nomatron servers share one PostgreSQL database;
  5. Nomatron servers use Serf to maintain cluster membership;
  6. private network agents connect to the Nomatron gRPC endpoint; and
  7. logs, metrics, backups, and secrets are managed by surrounding platform services.

In plain terms, the architecture separates into four layers:

  • edge and DNS;
  • Nomatron server nodes;
  • durable backing services;
  • connected Nomad and VCS systems.

Core Components

1. DNS And Public Entry Point

Use a stable public hostname for the Nomatron UI and API, for example:

text
https://nomatron.example.com

That hostname should front a load balancer or ingress layer rather than a single Nomatron server directly.

2. Load Balancer

Nomatron servers are designed to run behind a load balancer.

Because the servers are stateless, the load balancer can send a user request to any healthy Nomatron server instance. Session affinity is usually not required.

The recommended health probe target is:

text
/api/v1/health

This matters because the health endpoint reflects more than just HTTP reachability. It also includes readiness information for:

  • the database;
  • Serf; and
  • licensing state.

That means the load balancer can make a better availability decision than a simple TCP probe. In practice, this gives you a Serf-aware availability signal without needing the load balancer to probe Serf directly.

3. Nomatron Server Cluster

For production-style environments, run Nomatron as a small server cluster rather than a single server.

The recommended steady-state shape is:

  • 3 Nomatron servers;
  • each on a different host or VM;
  • all behind one load balancer;
  • all pointing at the same PostgreSQL database; and
  • all joined through Serf with gossip encryption enabled.

This gives you:

  • resilience to single-node failure;
  • rolling upgrade flexibility;
  • stable public access through the load balancer; and
  • internal coordination through Serf.

4. PostgreSQL

PostgreSQL is the durable system of record for Nomatron.

Treat it as a first-class production dependency:

  • managed separately from Nomatron servers;
  • backed up;
  • monitored;
  • secured with TLS where appropriate; and
  • sized for the control-plane workload you expect.

Do not treat Nomatron server allocations or containers as the place to host an ad hoc production database.

5. Private Network Agents

If you use private network agents, make sure the Nomatron gRPC port is reachable from those agents.

The current runtime shape is:

  • HTTP/UI/API on 4649
  • agent gRPC on 4650

The gRPC endpoint may be exposed differently from the public UI depending on your network model. Some operators keep the UI on a public or corporate edge while restricting the gRPC endpoint to private networks only.

6. Secrets, Identity, And Observability

A production deployment should also include:

  • secret delivery for database and license values;
  • TLS certificate management;
  • centralized logs;
  • metrics and alerting;
  • database backup and restore procedures; and
  • clear operator access boundaries.

Those surrounding systems are not optional “extras.” They are part of the real production architecture.

If you want a simple baseline to adapt anywhere, use this shape:

  • 1 DNS name for Nomatron
  • 1 load balancer
  • 3 Nomatron servers
  • 1 PostgreSQL database or managed HA database service
  • 1 secret delivery mechanism
  • 1 log and metrics pipeline

That is the architecture most teams should start from unless they are intentionally running a smaller staging or evaluation footprint.

High-Level Traffic Flow

The normal request path is:

  1. user opens https://nomatron.example.com;
  2. DNS resolves to the load balancer;
  3. the load balancer sends the request to a healthy Nomatron server;
  4. the Nomatron server reads and writes state in PostgreSQL;
  5. the Nomatron server coordinates with peer Nomatron servers through Serf; and
  6. where relevant, Nomatron connects onward to Nomad clusters, GitHub, and agents.

Health And Availability Model

For production, availability should be judged at three layers:

Edge Availability

The load balancer can reach at least one healthy Nomatron server.

Server Availability

Each server can:

  • start cleanly;
  • reach PostgreSQL;
  • report healthy on /api/v1/health; and
  • participate in Serf membership.

Data Availability

PostgreSQL remains reachable and healthy.

If the database is unavailable, Nomatron should not be considered healthy even if the HTTP process is technically still up.

The cleanest production shape usually looks like this:

  • Nomatron servers: stateless application tier
  • PostgreSQL: durable state tier
  • Load balancer: public entry and health-based routing
  • Secrets platform: configuration and sensitive values
  • Logging and metrics: observability tier

Keeping those responsibilities separate makes upgrades, troubleshooting, and security boundaries much easier to manage.

AWS Recommendation

On AWS, a strong default architecture is:

  • Route 53 for DNS
  • Application Load Balancer for the UI and HTTP API
  • Nomatron servers on Nomad clients running on EC2
  • Amazon RDS for PostgreSQL
  • AWS Secrets Manager or Vault for secrets
  • CloudWatch or your preferred observability stack for logs and metrics

[DIAGRAM PLACEHOLDER: AWS reference architecture diagram]

AWS Notes

  • Use an ALB health check against /api/v1/health
  • Place Nomatron servers in private subnets behind the ALB
  • Keep the gRPC endpoint private unless there is a strong reason to expose it more broadly
  • Spread Nomatron servers across different EC2 instances and preferably different availability zones
  • Use RDS Multi-AZ or another HA PostgreSQL pattern for the database tier

AWS Recommendation Summary

If you want a short AWS recommendation:

  • Route 53
  • ALB
  • 3 Nomatron servers on Nomad-managed EC2
  • RDS PostgreSQL
  • Secrets Manager or Vault

Azure Recommendation

On Azure, a strong default architecture is:

  • Azure DNS for DNS
  • Azure Application Gateway or Azure Load Balancer at the edge
  • Nomatron servers on Nomad clients running on Azure VMs
  • Azure Database for PostgreSQL
  • Azure Key Vault or Vault for secrets
  • Azure Monitor or your preferred observability stack for logs and metrics

[DIAGRAM PLACEHOLDER: Azure reference architecture diagram]

Azure Notes

  • Probe /api/v1/health from the ingress or load-balancer layer
  • Keep Nomatron servers on separate VMs or VM scale set instances
  • Use availability zones where practical
  • Put PostgreSQL on a managed highly available offering rather than co-locating it with Nomatron
  • Keep agent gRPC exposure private unless your topology requires otherwise

Azure Recommendation Summary

If you want a short Azure recommendation:

  • Azure DNS
  • Application Gateway
  • 3 Nomatron servers on Nomad-managed VMs
  • Azure Database for PostgreSQL
  • Key Vault or Vault

Google Cloud Recommendation

On Google Cloud, a strong default architecture is:

  • Cloud DNS for DNS
  • Google Cloud Load Balancing for the UI and HTTP API
  • Nomatron servers on Nomad clients running on Compute Engine
  • Cloud SQL for PostgreSQL
  • Secret Manager or Vault for secrets
  • Cloud Logging and Cloud Monitoring or your preferred observability stack

[DIAGRAM PLACEHOLDER: Google Cloud reference architecture diagram]

Google Cloud Notes

  • Use the Nomatron health endpoint for backend health checks
  • Spread the Nomatron server nodes across different Compute Engine instances and zones
  • Keep the PostgreSQL tier managed and separate from the Nomatron server tier
  • Protect the gRPC listener with private networking where possible
  • Keep the public hostname stable and aligned with server.api_addr

Google Cloud Recommendation Summary

If you want a short GCP recommendation:

  • Cloud DNS
  • Cloud Load Balancing
  • 3 Nomatron servers on Nomad-managed Compute Engine
  • Cloud SQL for PostgreSQL
  • Secret Manager or Vault

Sizing Guidance

Exact sizing depends on workload and tenancy shape, and these recommendations should be treated as conservative starting points rather than benchmark-backed hard limits.

At the time of writing, these values are meant to help operators choose a reasonable first production footprint before formal load testing exists.

Why Horizontal Scale Is Usually Better

Because Nomatron servers are stateless, horizontal scale is usually the cleaner path than building one very large server.

In general:

  • more Nomatron servers allow the deployment to absorb more concurrent control-plane load;
  • additional servers improve availability and rolling-upgrade flexibility; and
  • PostgreSQL and surrounding infrastructure still remain part of the real scaling limit.

So the right pattern is usually:

  • start with a sensible per-node size;
  • run multiple Nomatron servers;
  • observe real usage; then
  • scale server count and database capacity together.

Evaluation Or Small Internal Environment

For evaluation, sandboxes, or lightweight internal environments, a reasonable starting point is:

  • 1 Nomatron server
  • 2 vCPU
  • 4 GB RAM
  • external PostgreSQL

This is enough for early testing and low-risk internal use, but it is not the recommended long-term production shape.

Production Starting Point

For a first real production deployment, a good starting point is:

  • 3 Nomatron servers
  • 2-4 vCPU per server
  • 4-8 GB RAM per server
  • one external PostgreSQL service sized and monitored separately

That is intentionally conservative. It gives operators room for:

  • rolling restarts;
  • higher availability;
  • growth in API and UI concurrency; and
  • more control-plane activity across organizations, apps, jobs, and agents.

VM Sizing Guidance

If you are running Nomatron directly on VMs, a practical starting point is:

EnvironmentNomatron serversPer-server CPUPer-server memory
Evaluation12 vCPU4 GB
Production starting point32-4 vCPU4-8 GB

For production, prefer three modest servers over one large server unless you have a very specific operational reason not to.

Docker Runtime Guidance

If you are running Nomatron as a Docker container, translate the VM guidance into container resource limits and reservations.

A reasonable starting point is:

  • evaluation:
    • 2 vCPU
    • 4 GB RAM
  • production starting point per container:
    • 2-4 vCPU
    • 4-8 GB RAM

The exact syntax depends on how you run Docker, but the operational goal is to avoid:

  • starving the Nomatron server under bursty control-plane activity; or
  • overcommitting memory so aggressively that the container is killed under routine load.

Nomad Resource Guidance

If you are running Nomatron on Nomad, a reasonable initial task sizing target is:

  • evaluation:
    • cpu = 1000-2000
    • memory = 4096
  • production starting point per Nomatron server:
    • cpu = 2000-4000
    • memory = 4096-8192

Those values are intentionally phrased as starting ranges rather than one exact recommendation.

The right choice depends on:

  • number of organizations;
  • application and job volume;
  • deployment activity;
  • health and drift activity;
  • agent usage; and
  • UI and API concurrency.

PostgreSQL Still Matters

Even if you add more Nomatron servers, the database still matters.

Operators should plan for PostgreSQL to scale with:

  • control-plane data volume;
  • connection count;
  • backup expectations; and
  • high-availability requirements.

Adding more Nomatron servers without watching the database tier can move the bottleneck rather than remove it.

Small Environment Variant

For smaller internal or staging environments, a reduced version is reasonable:

  • one load balancer
  • one Nomatron server
  • one PostgreSQL instance

That is acceptable for evaluation or low-risk internal use, but it is not the best long-term production posture.

Production Best Practices

Across all clouds, the most important practices are:

  • run Nomatron behind a load balancer;
  • use /api/v1/health for availability decisions;
  • treat PostgreSQL as a critical external dependency;
  • run multiple Nomatron servers for production;
  • place those servers on different hosts;
  • secure Serf gossip with an encryption key;
  • keep the gRPC path reachable only where needed; and
  • manage secrets and certificates outside the Nomatron runtime itself.

After this page, the most natural next pages are: