Skip to content

Discover the facts of the Cardano node for the setup command #3677

Done

Description

@jpraynaud

Why

The SPO one command onboarding must configure the Mithril signer and the DMQ node from what the running Cardano node already knows, instead of asking the operator to copy these values by hand.

What

Discover the facts of the Cardano node running on the machine, and expose them so that they can be used by the orchestrator.

How

  • Detect the Cardano node running as a host process or a systemd service
  • Collect the facts of the Cardano node:
    • Node instance (process and systemd unit)
    • Socket path
    • Database directory
    • Node configuration file
    • Topology file
    • KES key and operational certificate paths
    • Listening address and port
    • Service user
    • Node version
    • cardano-cli path?
  • Derive the facts needed by the signer and the DMQ node:
    • Cardano network
    • Shelley genesis file path
    • Role of the machine (block producer or relay or full-node)
    • Peers of the pool (relay address)
  • Support the cases where multiple Cardano nodes operate on a single machine
    • Several nodes without block producer return a error
    • Several block producer return a error
    • one block producer node or relay is ok
  • Report a Cardano node that is not supported yet (other implementation or containerized node)
    • Block producer using KES agent
  • How do we support multiple Cardano node versions with breaking changes in parameters discovery? -> We will respond that that later
  • Never open the KES key file
  • Keep the discovery behind traits so that other implementations and runtimes can be added later (depends on the prototype outcome)
  • switch logs from slog to tracing
  • log why a fact could not be discovered( command line parameter not present, file does not exist, unable to open file, unable to parse the JSON/YAML file)

Metadata

Metadata

Assignees

Labels

feature 🚀

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions