Skip to content

pragma-org/amaru

Repository files navigation

Amaru

Amaru is a Cardano node client written in Rust. It is an ambitious project which aims to bring more diversity to the infrastructure operating the Cardano network.

Getting Started

Warning

Amaru is still in an exploratory phase. Our development strategy favors early integration of components, so that progress is instantly visible, even though features might be limited or incomplete.

Installing

cargo build --release

Running (demo)

Important

These instructions assume one starts from scratch, and has access to a running cardano-node on the preprod network.

  1. Download at least three ledger snapshots:
mkdir -p snapshots;
curl -s -o - "https://raw.githubusercontent.com/pragma-org/amaru/refs/heads/main/data/snapshots.json" \
  | jq -r '.[] | "\(.point)  \(.url)"' \
  | while read p u ; do  \
      echo "Fetching $p.cbor"; \
      curl --progress-bar -o - $u \
        | gunzip > snapshots/$p.cbor ; \
    done
  1. Import the snapshots just downloaded, either individually or a full directory
cargo run --release -- import \
  --snapshot snapshots/69206375.6f99b5f3deaeae8dc43fce3db2f3cd36ad8ed174ca3400b5b1bed76fdf248912.cbor

# OR
cargo run --release -- import \
  --snapshot snapshots/69206375.6f99b5f3deaeae8dc43fce3db2f3cd36ad8ed174ca3400b5b1bed76fdf248912.cbor \
  --snapshot snapshots/70070379.d6fe6439aed8bddc10eec22c1575bf0648e4a76125387d9e985e9a3f8342870d.cbor

# OR
cargo run --release -- import --snapshot-dir snapshots
  1. Import chain data from remote peer
cargo run --release -- import-chain-db \
  --peer 127.0.0.1:3000 --starting-point 69638382.5da6ba37a4a07df015c4ea92c880e3600d7f098b97e73816f8df04bbb5fad3b7

Warning

This can take a while as the code is currently non-optimised.

  1. Setup observability backends:
docker-compose -f monitoring/jaeger/docker-compose.yml up
  1. Run the node:
AMARU_DEV_LOG=warn cargo run --release -- daemon \
  --peer-address=127.0.0.1:3000 \
  --network=preprod

Tip

Replace --peer-address with your Cardano node peer address. It can be either a local or remote node (i.e. any existing node relay).

Monitoring

See monitoring/README.md.

Going further

Amaru is the integration point of several other projects / repositories. Amongst them, we find in particular:

Repository Purpose
txpipe/pallas Hosts many Rust primitives and building blocks for the node already powering tools like Dolos. In particular, the networking and serialization logic.
pragma-org/ouroboros Rust libraries/building blocks to implement an Ouroboros (Praos & Genesis) consensus.
pragma-org/uplc A highly performant UPLC parser and CEK machine.

Roadmap | 📐 Contributing | Discord Discord

About

A node client for Cardano, written in Rust

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages