This project aims to export data from ZKSync Era to AvailDA.
This project contains different subprojects:
- validium: A Deno script to submit pubdata from ZKSync Era to Turing Avail DA and verify it (using Sepolia).
- avail-da: Docker containers to run an Avail DA node locally.
- da-sender: A Rust script to submit pubdata from ZKSync Era to the local Avail DA node.
- da-getter: A Rust script to retrieve data from the local Avail DA node.
- tools/web_scraper: Python script to automate claiming AVAIL tokens from the AVAIL Faucet website.
To run this project, you need to have installed:
The usage of this project is divided into two main scenarios:
- Using the Avail DA Turing Testnet
- Running Avail DA locally.
Each scenario provides different ways to interact with the data availability layer, either through a public testnet or a local setup.
To run the Deno script that retrieves pubdata from ZKSync Era
, sends it and verifies it using Turing Avail DA use the following command:
make validium
To set up and run Avail DA locally, execute the following command:
make avail-da
This command builds and starts the Docker containers necessary for running Avail DA on your local machine.
With the da-sender
script, after following the steps, you can send pubdata from ZKSync Era to the local Avail DA by running this command:
make send-data
This command uses the da-sender script to submit the pubdata to your locally running Avail DA node.
To set up the web scraper, navigate to the tools/web_scraper
directory and run:
make web-scraper
This command will create a virtual environment, install dependencies, and run the web scraper.
All commands are run from the root of the project, from a terminal:
Command | Action |
---|---|
make avail-da |
Builds and starts the Avail DA services locally using Docker |
make clean |
Stops and removes Docker containers and networks created by the project |
make build |
Builds the Docker images for Avail DA |
make avail-da-full |
Builds and runs the full Avail DA node with multiple exposed ports |
make avail-da-testnet |
Builds and runs the Avail DA node for the testnet environment |
make send-data |
Compiles and runs the da-sender Rust script to submit pubdata |
make send-custom-data |
Compiles and runs the da-sender Rust script with custom pubdata submission |
make get-data |
Compiles and runs the da-getter Rust script to retrieve data |
make format |
Formats the code in da-sender , da-getter , and validium directories |
make validium |
Runs the Deno script that retrieves pubdata from ZKSync Era , sends it and verifies it to Avail |
make validium-test |
Runs Deno tests |
make web-scraper |
Sets up the web scraper virtual environment, installs dependencies, and runs the scraper |
make web-scraper-install |
Installs dependencies for the web scraper |
make web-scraper-run |
Runs the web scraper to claim AVAIL tokens from the AVAIL Faucet website |
make web-scraper-venv |
Sets up the virtual environment for the web scraper |
make web-scraper-clean |
Cleans up the web scraper virtual environment and removes generated files |
make web-scraper-clean-logs |
Cleans up the logs generated by the web scraper |