-
Notifications
You must be signed in to change notification settings - Fork 5.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add forc-node command for easily bootstrapping a node #6473
base: master
Are you sure you want to change the base?
Conversation
bd90b81
to
4cab4db
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Small comments.
Also, can we remove the wasm bytecodes & benchmark JSON files? Those are not needed at runtime (it will pull updates from the live network if needed), and I don't like committing or shipping binary blobs in this repo if we can avoid it.
4cab4db
to
2db09cc
Compare
5873fab
to
fadc4ee
Compare
5e2f71c
to
91b8e10
Compare
opinion: I've seen cargo run -p forc-node -- --dry-run local --port 8090 It prints the following (port is missing):
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great work on this! 🏆
|
||
fn build_api_endpoint(&self, folder_name: &str) -> String { | ||
format!( | ||
"{}/repos/FuelLabs/{}/contents/{}", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we're always fetching from master, would this mean forc-node might be using a newer version of the chain config than what's actually deployed?
Co-authored-by: Sophie Dankel <[email protected]>
Co-authored-by: Sophie Dankel <[email protected]>
I'll move forc-node tests to a sepearate step because it needs fuel-core installed. That's why test workspace stuff is failing but the code itself is ready to be reviewed! @FuelLabs/tooling |
db7a38f
to
f59a38b
Compare
Description
WIP at the moment, I have couple of code duplications to remove but we can start playing with this.
Forc Node
Forc node is a new plugin for easily bootstrapping fuel-core instances with sensible defaults. We currently support:
Ignition
This configuration automatically syncs with ignition network, basically run
forc node ignition
and the created node instance will start syncing.The defaults are taken from: https://docs.fuel.network/guides/running-a-node/running-a-mainnet-node/
Testnet
This is for connecting to the latest testnet. Similar to mainnet only thing required is to run
forc node testnet
to start a node created for syncing with testnet.The defaults are taken from: https://docs.fuel.network/guides/running-a-node/running-a-testnet-node/
Local
This is a in-memory instance mostly suited for local developments with instant block production and debug mode enabled in the fuel-core level.
Dry run
It is possible that users of this new plugin might not want to run the node without seeing the parameters send to it. So forc-node has a dry run mode that can be enabled
forc-node --dry-run <ignition|testnet|local>
which will instead of running the node print the command that would achieve the same result:TODO