> ## Documentation Index
> Fetch the complete documentation index at: https://docs.kombify.io/llms.txt
> Use this file to discover all available pages before exploring further.

# stackkit drift

> Observe and reconcile local StackKit drift

Observe and reconcile local StackKit drift.

```bash theme={null}
stackkit drift [flags]
```

Subcommands: [`stackkit drift detect`](#stackkit-drift-detect), [`stackkit drift reconcile`](#stackkit-drift-reconcile)

## stackkit drift detect

Read the authoritative local state and report drift.

Read and verify the canonical ResolvedPlan, generated artifacts, owner-signed Apply evidence, local Owner binding, and live Basement Compose runtime without refreshing runtime state. The content-addressed report is retained as local Owner evidence for every selected Application Kit.

```bash theme={null}
stackkit drift detect [flags]
```

| Flag     | Type | Default | Description                          |
| -------- | ---- | ------- | ------------------------------------ |
| `--json` | bool | —       | Emit stackkit.command-result/v1 JSON |

**Examples**

```bash theme={null}
# Compare the live deployment with the applied plan
stackkit drift detect

# The same drift report as JSON
stackkit drift detect --json
```

## stackkit drift reconcile

Reconcile drift through the governed local lifecycle.

Standard mode requires explicit local Owner approval, verifies the current local authority, creates a mandatory Kopia and executor-state rollback checkpoint, then runs generate, apply, and verify through the exclusive lifecycle journal. A failed target phase automatically restores, reapplies, and verifies the captured prior executor state. Advanced mode remains fail-closed until an offline-verified capability is supplied.

```bash theme={null}
stackkit drift reconcile [flags]
```

| Flag               | Type   | Default    | Description                                                      |
| ------------------ | ------ | ---------- | ---------------------------------------------------------------- |
| `--candidate-spec` | string | —          | Advanced: exact Terramate candidate StackSpec                    |
| `--capability`     | string | —          | Advanced: canonical offline capability file                      |
| `--change-set`     | string | —          | Advanced: exact Owner-signed change-set ID                       |
| `--expect-sha256`  | string | —          | Advanced: exact stored change-set byte digest                    |
| `--json`           | bool   | —          | Emit stackkit.command-result/v1 JSON                             |
| `--mode`           | string | `standard` | Reconcile mode: standard or advanced                             |
| `--owner-approve`  | bool   | —          | Record explicit local Owner approval for standard reconciliation |

**Examples**

```bash theme={null}
# Reconcile drift in standard mode: checkpoint, then generate, apply, and verify
stackkit drift reconcile --owner-approve

# The same reconciliation with a JSON result
stackkit drift reconcile --owner-approve --json
```
