---
title: "validate site config on the load balancers · RUAL Documentation"
description: "Run nginx -t for this site config on every load balancer, in the context of its full live config. Writes nothing to any live directory."
canonical: https://docs.rual.nl/block-types/nginx/nginxsite_check
language: en
---

[Cluster](https://docs.rual.nl/cluster)

[Blocks](https://docs.rual.nl/block-types)

[Interfaces](https://docs.rual.nl/interfaces)

[Blueprints](https://docs.rual.nl/blueprints)

[Tutorials](https://docs.rual.nl/tutorials)

[Home automation](https://docs.rual.nl/home-automation)

[Examples](https://docs.rual.nl/examples)

[Reference](https://docs.rual.nl/reference)

[Architecture](https://docs.rual.nl/architecture)

[Troubleshooting](https://docs.rual.nl/troubleshooting)

Other

# validate site config on the load balancers

This block is part of the [`nginx`](https://docs.rual.nl/block-types/nginx) group and was last modified in core [`v15.0.0`](https://docs.rual.nl/core-versions/150000).

Run nginx -t for this site config on every load balancer, in the context of its full live config. Writes nothing to any live directory.

- flow `flow`

- Site required `value` The site name, for example example.com : becomes .conf on the fleet.

- Site config required `value` The nginx site config, exactly as it would be pushed.

- Load balancers required `array` Each {name, host, port, user, key_path, known_hosts_path}. Paths only : never key material.

- flow `flow`

- Success `condition` True when every node could be asked. Whether they passed is on the passed pin.

- Site `value` The site that was validated.

- Passed everywhere `condition` True only when nginx -t passed on every node. This is the gate the push needs.

- Results `array` Per node: name, host, ok, output, exit_code, checksum, site.

- Checksum `value` sha256 of the exact bytes checked. The push matches on this.

- Passed count `number` How many nodes accepted the config.

- Node count `number` How many nodes were asked.

- Error `value` Why the check could not run at all.

Validates an nginx site config on EVERY load balancer in the nodes list and reports per node. The far side overlays the staged file on a shadow of its full live tree and runs the real nginx -t, so the answer covers certificates, includes and interactions with the other live sites : not a syntax check in a vacuum. Nothing reaches a live directory. This is a separate fan-out ahead of any write: 'does this validate everywhere' is answered in full before 'shall we replace anything' is asked. passed comes back true only when every node passed. results carries {name, host, ok, output, exit_code, checksum, site} per node, and checksum is a sha256 of the exact bytes checked: nginxsite_push demands a passing result with a MATCHING checksum for every node it is about to write to, so a flow cannot check, edit and then push a different file. Each node is {name, host, port, user, key_path, known_hosts_path}; user defaults to lbpush. Key MATERIAL must never appear on the pin : only paths : and the block refuses a node object carrying private_key, key, password, passphrase or secret.

| `nginx -t` |
| --- |
| `validate nginx config` |
| `check site config` |

A typical wiring for [validate site config on the load balancers](https://docs.rual.nl/block-types/nginx/nginxsite_check): a [function trigger](https://docs.rual.nl/block-types/globals/trigger_custom_function) starts the flow; [value](https://docs.rual.nl/block-types/value/value_default) feeds the `site` pin; [value](https://docs.rual.nl/block-types/value/value_default) feeds the `config` pin; [with values](https://docs.rual.nl/block-types/array/array_of_values) feeds the `nodes` pin; the `flow` out pin feeds [debug](https://docs.rual.nl/block-types/state%2520ui/state_debug).

[![Studio canvas example for the validate site config on the load balancers block: typical wiring for validate site config on the load balancers.](https://docs.rual.nl/canvas-examples/nginxsite_check.png)](https://docs.rual.nl/canvas-examples/nginxsite_check.png?v=3)

## Version history

Introduced in [`v15.0.0`](https://docs.rual.nl/core-versions/150000).

- [Back to `nginx`](https://docs.rual.nl/block-types/nginx): Return to the main group to view all sub-groups

- [Back to `Load balancers`](https://docs.rual.nl/block-types/nginx?group=Load%20balancers): Return to the group to view all blocks within this group

Was this page helpful? [Tell us what to improve](https://docs.rual.nl/support) · RUAL Docs is an integral component of the [RUAL ecosystem](https://rual.nl)
