{"id":20975226,"url":"https://github.com/functionland/fula-node","last_synced_at":"2025-03-13T09:17:36.491Z","repository":{"id":243301130,"uuid":"811023781","full_name":"functionland/fula-node","owner":"functionland","description":null,"archived":false,"fork":false,"pushed_at":"2024-09-02T18:33:27.000Z","size":49481,"stargazers_count":0,"open_issues_count":10,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-01-20T05:43:11.183Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit-0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/functionland.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":"CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-06-05T19:47:55.000Z","updated_at":"2024-06-07T21:07:44.000Z","dependencies_parsed_at":"2024-06-07T22:25:59.217Z","dependency_job_id":"51773731-ab4d-4220-a3bb-285d48fd180f","html_url":"https://github.com/functionland/fula-node","commit_stats":null,"previous_names":["functionland/fula-node"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/functionland%2Ffula-node","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/functionland%2Ffula-node/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/functionland%2Ffula-node/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/functionland%2Ffula-node/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/functionland","download_url":"https://codeload.github.com/functionland/fula-node/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243374326,"owners_count":20280661,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-19T04:41:11.504Z","updated_at":"2025-03-13T09:17:36.458Z","avatar_url":"https://github.com/functionland.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Substrate Node Template\n\nA fresh [Substrate](https://substrate.io/) node, ready for hacking :rocket:\n\nA standalone version of this template is available for each release of Polkadot\nin the [Substrate Developer Hub Parachain\nTemplate](https://github.com/substrate-developer-hub/substrate-parachain-template/)\nrepository. The parachain template is generated directly at each Polkadot\nrelease branch from the [Node Template in\nSubstrate](https://github.com/paritytech/polkadot-sdk/tree/master/substrate/bin/node-template)\nupstream\n\nIt is usually best to use the stand-alone version to start a new project. All\nbugs, suggestions, and feature requests should be made upstream in the\n[Substrate](https://github.com/paritytech/polkadot-sdk/tree/master/substrate)\nrepository.\n\n## Getting Started\n\nDepending on your operating system and Rust version, there might be additional\npackages required to compile this template. Check the\n[Install](https://docs.substrate.io/install/) instructions for your platform for\nthe most common dependencies. Alternatively, you can use one of the [alternative\ninstallation](#alternatives-installations) options.\n\n### Build\n\nUse the following command to build the node without launching it:\n\n```sh\ncargo build --release\n```\n\n### Embedded Docs\n\nAfter you build the project, you can use the following command to explore its\nparameters and subcommands:\n\n```sh\n./target/release/node-template -h\n```\n\nYou can generate and view the [Rust\nDocs](https://doc.rust-lang.org/cargo/commands/cargo-doc.html) for this template\nwith this command:\n\n```sh\ncargo +nightly doc --open\n```\n\n### Single-Node Development Chain\n\nThe following command starts a single-node development chain that doesn't\npersist state:\n\n```sh\n./target/release/node-template --dev\n```\n\nTo purge the development chain's state, run the following command:\n\n```sh\n./target/release/node-template purge-chain --dev\n```\n\nTo start the development chain with detailed logging, run the following command:\n\n```sh\nRUST_BACKTRACE=1 ./target/release/node-template -ldebug --dev\n```\n\nDevelopment chains:\n\n- Maintain state in a `tmp` folder while the node is running.\n- Use the **Alice** and **Bob** accounts as default validator authorities.\n- Use the **Alice** account as the default `sudo` account.\n- Are preconfigured with a genesis state (`/node/src/chain_spec.rs`) that\n  includes several prefunded development accounts.\n\nTo persist chain state between runs, specify a base path by running a command\nsimilar to the following:\n\n```sh\n// Create a folder to use as the db base path\n$ mkdir my-chain-state\n\n// Use of that folder to store the chain state\n$ ./target/release/node-template --dev --base-path ./my-chain-state/\n\n// Check the folder structure created inside the base path after running the chain\n$ ls ./my-chain-state\nchains\n$ ls ./my-chain-state/chains/\ndev\n$ ls ./my-chain-state/chains/dev\ndb keystore network\n```\n\n### Connect with Polkadot-JS Apps Front-End\n\nAfter you start the node template locally, you can interact with it using the\nhosted version of the [Polkadot/Substrate\nPortal](https://polkadot.js.org/apps/#/explorer?rpc=ws://localhost:9944)\nfront-end by connecting to the local node endpoint. A hosted version is also\navailable on [IPFS (redirect) here](https://dotapps.io/) or [IPNS (direct)\nhere](ipns://dotapps.io/?rpc=ws%3A%2F%2F127.0.0.1%3A9944#/explorer). You can\nalso find the source code and instructions for hosting your own instance on the\n[`polkadot-js/apps`](https://github.com/polkadot-js/apps) repository.\n\n### Multi-Node Local Testnet\n\nIf you want to see the multi-node consensus algorithm in action, see [Simulate a\nnetwork](https://docs.substrate.io/tutorials/build-a-blockchain/simulate-network/).\n\n## Template Structure\n\nA Substrate project such as this consists of a number of components that are\nspread across a few directories.\n\n### Node\n\nA blockchain node is an application that allows users to participate in a\nblockchain network. Substrate-based blockchain nodes expose a number of\ncapabilities:\n\n- Networking: Substrate nodes use the [`libp2p`](https://libp2p.io/) networking\n  stack to allow the nodes in the network to communicate with one another.\n- Consensus: Blockchains must have a way to come to\n  [consensus](https://docs.substrate.io/fundamentals/consensus/) on the state of\n  the network. Substrate makes it possible to supply custom consensus engines\n  and also ships with several consensus mechanisms that have been built on top\n  of [Web3 Foundation\n  research](https://research.web3.foundation/en/latest/polkadot/NPoS/index.html).\n- RPC Server: A remote procedure call (RPC) server is used to interact with\n  Substrate nodes.\n\nThere are several files in the `node` directory. Take special note of the\nfollowing:\n\n- [`chain_spec.rs`](./node/src/chain_spec.rs): A [chain\n  specification](https://docs.substrate.io/build/chain-spec/) is a source code\n  file that defines a Substrate chain's initial (genesis) state. Chain\n  specifications are useful for development and testing, and critical when\n  architecting the launch of a production chain. Take note of the\n  `development_config` and `testnet_genesis` functions,. These functions are\n  used to define the genesis state for the local development chain\n  configuration. These functions identify some [well-known\n  accounts](https://docs.substrate.io/reference/command-line-tools/subkey/) and\n  use them to configure the blockchain's initial state.\n- [`service.rs`](./node/src/service.rs): This file defines the node\n  implementation. Take note of the libraries that this file imports and the\n  names of the functions it invokes. In particular, there are references to\n  consensus-related topics, such as the [block finalization and\n  forks](https://docs.substrate.io/fundamentals/consensus/#finalization-and-forks)\n  and other [consensus\n  mechanisms](https://docs.substrate.io/fundamentals/consensus/#default-consensus-models)\n  such as Aura for block authoring and GRANDPA for finality.\n\n### Runtime\n\nIn Substrate, the terms \"runtime\" and \"state transition function\" are analogous.\nBoth terms refer to the core logic of the blockchain that is responsible for\nvalidating blocks and executing the state changes they define. The Substrate\nproject in this repository uses\n[FRAME](https://docs.substrate.io/learn/runtime-development/#frame) to construct\na blockchain runtime. FRAME allows runtime developers to declare domain-specific\nlogic in modules called \"pallets\". At the heart of FRAME is a helpful [macro\nlanguage](https://docs.substrate.io/reference/frame-macros/) that makes it easy\nto create pallets and flexibly compose them to create blockchains that can\naddress [a variety of needs](https://substrate.io/ecosystem/projects/).\n\nReview the [FRAME runtime implementation](./runtime/src/lib.rs) included in this\ntemplate and note the following:\n\n- This file configures several pallets to include in the runtime. Each pallet\n  configuration is defined by a code block that begins with `impl\n$PALLET_NAME::Config for Runtime`.\n- The pallets are composed into a single runtime by way of the\n  [`construct_runtime!`](https://paritytech.github.io/substrate/master/frame_support/macro.construct_runtime.html)\n  macro, which is part of the [core FRAME pallet\n  library](https://docs.substrate.io/reference/frame-pallets/#system-pallets).\n\n### Pallets\n\nThe runtime in this project is constructed using many FRAME pallets that ship\nwith [the Substrate\nrepository](https://github.com/paritytech/polkadot-sdk/tree/master/substrate/frame) and a\ntemplate pallet that is [defined in the\n`pallets`](./pallets/template/src/lib.rs) directory.\n\nA FRAME pallet is comprised of a number of blockchain primitives, including:\n\n- Storage: FRAME defines a rich set of powerful [storage\n  abstractions](https://docs.substrate.io/build/runtime-storage/) that makes it\n  easy to use Substrate's efficient key-value database to manage the evolving\n  state of a blockchain.\n- Dispatchables: FRAME pallets define special types of functions that can be\n  invoked (dispatched) from outside of the runtime in order to update its state.\n- Events: Substrate uses\n  [events](https://docs.substrate.io/build/events-and-errors/) to notify users\n  of significant state changes.\n- Errors: When a dispatchable fails, it returns an error.\n\nEach pallet has its own `Config` trait which serves as a configuration interface\nto generically define the types and parameters it depends on.\n\n## Alternatives Installations\n\nInstead of installing dependencies and building this source directly, consider\nthe following alternatives.\n\n### Nix\n\nInstall [nix](https://nixos.org/) and\n[nix-direnv](https://github.com/nix-community/nix-direnv) for a fully\nplug-and-play experience for setting up the development environment. To get all\nthe correct dependencies, activate direnv `direnv allow`.\n\n### Docker\n\nPlease follow the [Substrate Docker instructions\nhere](https://github.com/paritytech/polkadot-sdk/blob/master/substrate/docker/README.md) to\nbuild the Docker container with the Substrate Node Template binary.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffunctionland%2Ffula-node","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffunctionland%2Ffula-node","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffunctionland%2Ffula-node/lists"}