The data syncer of CoTA Script.
First you need to create a database, the default database name is cota_entries
. You can adjust it according to your needs.
For the testnet, you can execute the following SQL statement to syn from a specific height:
insert into check_infos (check_type, block_number, block_hash, created_at, updated_at) values (0, 4163980, 'ab6d9453628ee854062615acf05f899e8c84e4e61d417d0b13bbed128a862e23', now(), now());
insert into check_infos (check_type, block_number, block_hash, created_at, updated_at) values (1, 4163980, 'ab6d9453628ee854062615acf05f899e8c84e4e61d417d0b13bbed128a862e23', now(), now());
Second you need to start a ckb node, You can refer to the following tutorial Run a CKB Testnet Node.
Update the configuration file according to your specific situation.
app section in the config file has a mode config, can be configured as wild
to turn on chase mode.
Enter this project directory and execute make
.
Execute bin/syncer
tail -f storage/logs/app.logger