{"id":21754466,"url":"https://github.com/e00dan/nervos-godwoken-testnet-node","last_synced_at":"2025-04-13T09:08:10.240Z","repository":{"id":43081780,"uuid":"401836756","full_name":"e00dan/nervos-godwoken-testnet-node","owner":"e00dan","description":"Run Nervos Layer 2 (Godwoken) Testnet Node","archived":false,"fork":false,"pushed_at":"2022-03-19T20:37:01.000Z","size":58,"stargazers_count":4,"open_issues_count":2,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-13T09:08:04.999Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/e00dan.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-08-31T20:36:42.000Z","updated_at":"2023-01-31T01:12:34.000Z","dependencies_parsed_at":"2022-08-24T00:00:52.832Z","dependency_job_id":null,"html_url":"https://github.com/e00dan/nervos-godwoken-testnet-node","commit_stats":null,"previous_names":["e00dan/nervos-godwoken-testnet-node"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/e00dan%2Fnervos-godwoken-testnet-node","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/e00dan%2Fnervos-godwoken-testnet-node/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/e00dan%2Fnervos-godwoken-testnet-node/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/e00dan%2Fnervos-godwoken-testnet-node/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/e00dan","download_url":"https://codeload.github.com/e00dan/nervos-godwoken-testnet-node/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248688565,"owners_count":21145766,"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-26T09:14:03.245Z","updated_at":"2025-04-13T09:08:10.212Z","avatar_url":"https://github.com/e00dan.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Nervos Godwoken Layer 2 Node Easy Deploy\n\nThis repo contains Docker Compose files to deploy a Godwoken testnet or mainnet node.\n\n## Basic Requirements\n\n### Software\n\n- Docker\n- Docker Compose\n- Git\n- Curl\n\n### Ports\n\n- 8119\n- 8024\n\n## Configuration\n\nThe default configuration can be used without modification. However, it is recommended that the RPC nodes for the CKB node and CKB Indexer node be updated. The `3.235.223.161` node is a temporary public node that will disappear in the future. It is much faster and reliable to use locally hosted nodes for both.\n\nThe node IPs can be configured in the `[rpc_client]` section of the following file:\n\n- config/godwoken-readonly-config.toml\n\nChanging the ports can be configured by editing the following:\n\n- config/godwoken-readonly-config.toml\n- config/web3.env\n- docker-compose.yml\n\n## Basic Usage\n\nEnter the `testnet` or `mainnet` directory, then execute `docker-compose up` to launch.\n\nFor launching the testnet:\n\n```sh\ncd testnet\ndocker-compose up\n```\n\nFor launching the mainnet:\n\n```sh\ncd mainnet\ndocker-compose up\n```\n\nNote: You cannot run both the testnet and mainnet at the same time because they will both try to use ports `8119` and `8024`. This must be reconfigred in order to run them both on the same machine.\n\n## Testing\n\n### 1. Get Transaction (Godwoken RPC; Testnet)\n\n**Sync at least 30 blocks**, then execute the following command:\n\n```sh\ncurl http://localhost:8119 -X POST -H \"Content-Type: application/json\" -d '{\"jsonrpc\": \"2.0\", \"method\":\"gw_get_transaction\", \"params\": [\"0x7589fb1689b53700cec9966e16b83714f3583ec30d6184a782d329649c40d37e\"], \"id\": 1}'\n```\n\nExpected result:\n\n```txt\n{\"jsonrpc\":\"2.0\",\"result\":{\"transaction\":{\"raw\":{\"from_id\":\"0x2\",\"to_id\":\"0x5\",\"nonce\":\"0x5\",\"args\":\"0xffffff504f4c590040420f00000000000000000000000000000000000000000000000000000000000000000000000000a40000009623609d000000000000000000000000fe1cae6e56bbb423821c71c685edfcda39d41d15000000000000000000000000a2694d757143110690f93de88ac1e345cb2c276500000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000004d09de08a00000000000000000000000000000000000000000000000000000000\"},\"signature\":\"0xc772ed5473e1b5eb5ad55ae87dcfe9dadba15003ad3fc715d04ae29938b4f1d320aebaeac14c5946743d07a054733f62f64ad57024fbd3ff543ee463d8abf8af00\",\"hash\":\"0x7589fb1689b53700cec9966e16b83714f3583ec30d6184a782d329649c40d37e\"},\"status\":\"committed\"},\"id\":1}\n```\n\n### 2. Block Number\n\n```sh\ncurl http://localhost:8024 -X POST -H \"Content-Type: application/json\" -d '{\"jsonrpc\": \"2.0\", \"method\":\"eth_blockNumber\", \"params\": [], \"id\": 1}'\n```\n\nExpected result (example):\n\n```txt\n{\"jsonrpc\":\"2.0\",\"id\":1,\"result\":\"0x430\"}\n```\n\n### 3. Syncing\n\n```sh\ncurl http://localhost:8024 -X POST -H \"Content-Type: application/json\" -d '{\"jsonrpc\": \"2.0\", \"method\":\"eth_syncing\", \"params\": [], \"id\": 1}'\n```\n\nExpected result (example):\n\n```txt\n{\"jsonrpc\":\"2.0\",\"id\":1,\"result\":{\"startingBlock\":\"0x380\",\"currentBlock\":\"0x380\",\"highestBlock\":\"0x380\"}}\n```\n\n### 4. Get Transaction (Testnet)\n\nRequirements:\n\n- Sync at least 30 blocks\n\n```sh\ncurl http://localhost:8024 -X POST -H \"Content-Type: application/json\" -d '{\"jsonrpc\": \"2.0\", \"method\":\"eth_getTransactionByHash\", \"params\": [\"0x7589fb1689b53700cec9966e16b83714f3583ec30d6184a782d329649c40d37e\"], \"id\": 1}'\n```\n\nExpected result:\n\n```txt\n{\"jsonrpc\":\"2.0\",\"id\":1,\"result\":{\"hash\":\"0x7589fb1689b53700cec9966e16b83714f3583ec30d6184a782d329649c40d37e\",\"blockHash\":\"0x3db5355a9146c0697c15c091d174b0d0f4b6e59c0beeff92f0def2e42389785d\",\"blockNumber\":\"0x1e\",\"transactionIndex\":\"0x0\",\"from\":\"0x8069d75814b6886ef39a5b3b0e84c3601b033480\",\"to\":\"0x1b9d4121479f1708addae44631bf174a6b00cd93\",\"gas\":\"0xf4240\",\"gasPrice\":\"0x0\",\"input\":\"0x9623609d000000000000000000000000fe1cae6e56bbb423821c71c685edfcda39d41d15000000000000000000000000a2694d757143110690f93de88ac1e345cb2c276500000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000004d09de08a00000000000000000000000000000000000000000000000000000000\",\"nonce\":\"0x5\",\"value\":\"0x0\",\"v\":\"0x0\",\"r\":\"0xc772ed5473e1b5eb5ad55ae87dcfe9dadba15003ad3fc715d04ae29938b4f1d3\",\"s\":\"0x20aebaeac14c5946743d07a054733f62f64ad57024fbd3ff543ee463d8abf8af\"}}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fe00dan%2Fnervos-godwoken-testnet-node","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fe00dan%2Fnervos-godwoken-testnet-node","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fe00dan%2Fnervos-godwoken-testnet-node/lists"}