diff --git a/README.md b/README.md index bf8c21e..e9886f4 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ A Go CLI that bootstraps and manages Polkadot parachain and solochain nodes. A s - **Snapshot sync** — Download chain data via rclone (Polkadot-style) or tar archives - **Chainspec download** — Optional `chainspec_url` to fetch chain/relay chain specs; when set, config `chain_spec` is ignored and the node uses the downloaded file - **Idempotent bootstrap** — Shell commands run once; state tracked in JSON file -- **Fixed data layout** — Predefined volume paths (no user overrides) matching Parity Helm chart patterns +- **Fixed data layout** — Predefined volume paths (no user overrides) matching Parity Helm chart patterns; under `chains/`, the directory name follows Substrate (hyphens in YAML `chain_id` become underscores on disk) - **Signal forwarding** — Graceful shutdown propagates SIGINT/SIGTERM to the node process ## Requirements diff --git a/docs/CONFIG.md b/docs/CONFIG.md index 36eaa44..57b995a 100644 --- a/docs/CONFIG.md +++ b/docs/CONFIG.md @@ -37,7 +37,7 @@ Mirrors Parity node chart [`chainData`](https://github.com/paritytech/helm-chart | Field | Default | Description | | ----------- | ---------- | ----------- | | `database` | `rocksdb` | `rocksdb` (DB dir `db`) or `paritydb` (DB dir `paritydb`); passed as `--database` | -| `chain_id` | (required) | Segment for `.../chain-data/chains//...`; same role as helm `CHAIN_PATH` / `node.chain` | +| `chain_id` | (required) | Logical id (same role as helm `CHAIN_PATH` / `node.chain`); on disk under `chains/` Substrate uses hyphens→underscores (e.g. `avn-paseo-v2` → `avn_paseo_v2`) | #### Other `chain` fields @@ -52,7 +52,7 @@ Mirrors Parity node chart [`chainData`](https://github.com/paritytech/helm-chart | `bootnodes` | `[]` | Chain bootnodes | | `override_bootnodes` | `[]` | When set, replaces `bootnodes` | | `extra_args` | `[]` | Extra CLI args (RPC, offchain-worker, etc.) | -| `snapshot_url` | `""` | Snapshot URL (rclone or tar); data goes under `chains//` | +| `snapshot_url` | `""` | Snapshot URL (rclone or tar); data goes under `chains//` (see `chain_id` row) | | `relay_chain_light_client` | `false` | **Parachain only.** Adds `--relay-chain-light-client` to chain args (experimental; full-node embedded relay light client using `relay_chain` chainspec). Disables relay-chain snapshot sync; do not set `relay_chain.snapshot_url`. | \* Either `chain_spec` or `chainspec_url` is required. @@ -68,7 +68,7 @@ Same semantics as `chain.chain_data` for relay data under `/data/relaychain-data | Field | Default | Description | | ----------- | ----------- | ----------- | | `database` | `rocksdb` | `rocksdb` or `paritydb` | -| `chain_id` | `polkadot` | Relay `chains//` segment (override e.g. `paseo`, `kusama`) | +| `chain_id` | `polkadot` | Relay logical id; on-disk segment under `chains/` uses Substrate naming (hyphens→underscores) | #### Other `relay_chain` fields @@ -142,7 +142,7 @@ Set `chainspec_url` under `chain` or `relay_chain` to download the chainspec bef ## Snapshot Sync -- **Tar archives**: Use a URL ending in `.tar.gz`, `.tar.lz4`, `.tar.zst`, etc. Extracted to `/data/chain-data/chains///` (and relay analogue). +- **Tar archives**: Use a URL ending in `.tar.gz`, `.tar.lz4`, `.tar.zst`, etc. Extracted to `/data/chain-data/chains///` (normalized = Substrate dir name: hyphens in `chain_id` become underscores; relay analogue under relaychain-data). - **Polkadot-style** (rclone): Use base URL (e.g. `https://snapshots.polkadot.io/...`). `chain_id` must match the snapshot chain id. Base URLs without a version suffix auto-resolve the latest snapshot. - **Backend vs snapshot**: Official Polkadot snapshots use ParityDB — set `chain_data.database: paritydb` (and the same for relay) so files land under `paritydb/` where the node expects them. Default `rocksdb` uses the `db/` directory.