You need to set up 5 components for local testing.
- WAO Server
- WeaveDB on AO
- Rollup Node
- WeaveLayer on AO
- Frontend Demo
npx wao
Check that the following units are running.
- Arweave : localhost:4000
- MU : localhost:4002
- SU : localhost:4003
- CU : localhost:4004
Clone the repo and install dependencies.
git clone https://github.com/weavedb/weavedb-ao.git
cd weavedb-ao/lua && yarn
mkdir scripts/.wallets
Under scripts/.wallets
, prepare the following wallets.
- Owner (
owner.json
| Arweave ) - Bundler (
bundler.json
| Arweave ) - DB-Creator (
db.json
| Arweave ) - Validator1 (
validator1.json
| Arweave ) - Validator2 (
validator2.json
| Arweave ) - Delegator (
delegator.json
| Arweave ) - Rollup-Admin (
admin.json
| EVM ) - ZK-Committer (
committer.json
| EVM )
The zk-committer must have a positive ETH balance. Alchemy has a faucet for Sepolia.
Or you can generate missing wallets.
node scripts/gen_wallets.js
Create .env
in weavedbb-ao/lua
directory and specify alchemy key.
ALCHEMY=XXXXXXXXXXXXXXXXXXXX
Deploy contracts.
node scripts/deploy_all.js
In another terminal, run envoy so frontend apps can access via port 8080.
cd weavedb-ao
yarn envoy
Now start the rollup node in another terminal.
cd weavedbb-ao/node/node-server && yarn
node index.js
Set up staking.
node scripts/setup_staking.js
In anotehr terminal, run the demo app.
cd weavedb-ao/demo && yarn
yarn dev
Now, the demo is runnint at localhost:3000.