> This page is for Remediation Orchestrator.

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.nvidia.com/remediation-orchestrator/llms.txt.

# Getting Started

> Run a local Remediation Orchestrator breakfix demonstration or deploy with Helm, then write your own workflow.

Choose how to run Remediation Orchestrator:

* On your machine: follow the local breakfix demonstration below.
* On Kubernetes: follow the [Local K8s quick start](/remediation-orchestrator/deployment/helm/quick-start/local-k8s) to try the full stack on a local cluster, or the [Shared K8s quick start](/remediation-orchestrator/deployment/helm/quick-start/shared-k8s) to deploy on an existing cluster.

The local NVIDIA Remediation Orchestrator (NRO) breakfix demonstration uses an
HTTP entrypoint, a scheduled poller, and an agent-assisted remediation workflow.
It uses a disposable MiniSlurm cluster and BCM simulator; it does not connect to
a real cluster.

## Prerequisites

* Git and a checkout of this repository.
* Bazelisk, which uses the pinned Bazel version and downloads the Go toolchain.
* A running Docker daemon with Compose and Buildx. Allow at least 8 GiB of
  Docker memory and 10 GiB of free disk space.
* An OpenAI-compatible LLM endpoint and a model capable of generating Starlark. A local
  endpoint is supported; a hosted subscription is not required. Set its URL,
  API key, and model below. Use the endpoint's documented placeholder key if
  your local server does not require authentication.
* Free local ports: 2223, 5432, 5433, 6787, 7233, 8080, 8081, 8090, and 10443.

## Run NRO

Clone the repository and configure the LLM endpoint in your shell:

```sh
git clone https://github.com/dsx-ai-factory/remediation-orchestrator.git
cd remediation-orchestrator

export LLM_BASE_URL="https://llm.example.com/v1"
export LLM_API_KEY="<your-api-key>"
export LLM_MODEL="<model-id>"
```

Build and start the complete example with one command:

```sh
bazelisk run //examples/quickstart
```

The command:

1. Checks prerequisites and port availability.
2. Builds NRO, production frontend assets, the BCM simulator, and MiniSlurm.
3. Starts PostgreSQL, Temporal, and Temporal UI in a dedicated Compose project,
   then initializes Temporal search attributes.
4. Starts four MiniSlurm workers and records the controller's SSH host key
   through the trusted local Docker connection.
5. Loads `examples/starlark/breakfix`, waits for `worker-1` to appear in NRO,
   submits its drain request, and waits for that workflow to complete.
6. Triggers the remediation poller and prints workflow IDs and Temporal links.

The first build can take several minutes while dependencies are downloaded and
MiniSlurm is built from source. Subsequent launches reuse build caches. Each
launch uses fresh databases and a separate fixture identity.

## Watch the workflow

Open [NRO](http://localhost:6787) and [Temporal UI](http://localhost:8080).
Use the printed workflow links to follow the drain request and poller. Expand
child workflows to inspect `remediate_node`, its state machine, and the agent.
Agent iterations and tool calls are available on the
[agent debug page](http://localhost:6787/system/agents).

The launcher pauses the scheduled poller and waits for any existing run to finish
before submitting the demonstration, so its printed poller link contains the
remediation. The workflow drains `worker-1`, checks its Slurm and BCM state, asks the agent to
power it on through the simulator, validates the result, and resumes the worker.
A successful run records `resolved`. If the investigation cannot safely finish,
it records `needs_attention` and leaves the worker drained. Inspect the poller's
result and activity history: a completed poller can report an unsuccessful
remediation. LLM provider errors and model choices can affect the outcome.

## Stop and rerun

Keep the command running while inspecting the UI. Press `Ctrl-C` to stop NRO
and the simulators, then remove the dedicated Compose project and its volumes.
**The quickstart databases are disposable and are deleted on shutdown**, including
startup failures. Logs remain in the temporary directory printed by the command.
The local MiniSlurm image remains cached.

Run the same command again for a fresh demonstration. The launcher does not
replace other MiniSlurm fixtures or stop other Compose projects. Existing
services occupying the required ports must be stopped first.

## Troubleshooting

* **Missing LLM settings:** export all three variables before running the command.
  Credentials are passed through the environment, not written into configuration.
* **Docker unavailable:** start the Docker daemon and verify `docker info`,
  `docker compose version`, and `docker buildx version` work.
* **Port already in use:** stop the conflicting service. This includes a local
  development stack already using PostgreSQL or Temporal ports.
* **Build or startup failure:** inspect `setup.log`, `image.log`, `minislurm.log`,
  `bcm.log`, `nro.log`, and `compose.log` in the printed log directory.
* **Inventory or workflow timeout:** the default timeout for each wait is 1200
  seconds, allowing margin beyond the example agent's 10-minute timeout. Startup
  readiness failures stop and delete the disposable stack. After a workflow wait
  expires or a workflow reports failure, the launcher keeps the stack and Temporal
  history available until you press `Ctrl-C`. Inspect the printed workflow links
  and logs. Increase the wait for a slow machine or model:

  ```sh
  bazelisk run //examples/quickstart -- --timeout=1800
  ```

The downloadable [docker-compose.yml](https://github.com/dsx-ai-factory/remediation-orchestrator/blob/1785e695a8bff76c910115b3c96398a5a59a7183/docker-compose.yml)
contains the same PostgreSQL and Temporal dependencies used by the launcher.
It does not build NRO, start the simulators, or submit a workflow by itself.
The quickstart requires a source checkout.

For hosted deployments, follow the [deployment checklist](/remediation-orchestrator/guides/deployment-checklist)
with your own configuration and secrets.

## Write your own workflow

NRO's internal indexing workflows start on their own and can appear in Temporal
before you add your own scripts.

Continue with [Your First Script](/remediation-orchestrator/guides/first-scripts-checklist) to write, upload and run your own workflow.