Skip to content

Commit a5b9dcc

Browse files
Merge branch 'main' of https://github.com/0xPolygon/polygon-docs into cdk/native-gas-token
2 parents e950f1c + add2d52 commit a5b9dcc

File tree

8 files changed

+93
-8
lines changed

8 files changed

+93
-8
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,4 @@ node_modules/
99
.DS_Store
1010
**/.DS_Store
1111
*.iml
12+
temp_dir/
File renamed without changes.

docs/cdk/get-started/deploy-rollup/intro.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
1-
This quick start takes you through the process of deploying a full CDK zkRollup, EVM-compatible network on Goerli.
1+
This tutorial takes you through the process of deploying a full CDK zkRollup, EVM-compatible network on Goerli.
2+
3+
It relies on specific component versions so we have hidden most of the configuration complexity in scripts to make the process straightforward.
24

35
!!! warning
4-
- These instructions are subject to frequent updates as the software remains at an early development stage.
6+
- The tutorial is for learning purposes only and is not intended to describe a latest stable version build.
57
- Report any content issues on our docs repo: https://github.com/0xPolygon/polygon-docs
68

79
The process is split into the following sections:

docs/cdk/get-started/deploy-validium/intro.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,11 @@
22
comments: true
33
---
44

5-
This guide takes you through the process of deploying a fully EVM-compatible, CDK validium on the Sepolia network.
5+
This tutorial takes you through the process of deploying a fully EVM-compatible, CDK validium on the Sepolia network.
66

7-
We have hidden most of the configuration complexity in scripts to make the process straightforward and easy to follow.
7+
It relies on specific component versions so we have hidden most of the configuration complexity in scripts to make the process straightforward and easy to follow.
8+
9+
The tutorial is for learning only and is not intended to describe a latest stable version build.
810

911
## Process steps
1012

Lines changed: 78 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,78 @@
1+
Polygon AggLayer is a web service that receives zero-knowledge proofs from different CDK chains and checks their soundness before sending the proof to L1 for verification.
2+
3+
!!! warning
4+
- The AggLayer is in development and subject to architectural changes.
5+
- The code is still being audited.
6+
7+
## Prerequisites
8+
9+
Make sure you have the following software installations.
10+
11+
- [Docker](https://docs.docker.com/engine/install/)
12+
- [Docker Compose](https://docs.docker.com/compose/install/)
13+
- [Golang](https://go.dev/doc/install)
14+
- [GCloud cli](https://cloud.google.com/sdk/docs/install) - production only.
15+
16+
### Clone the repo.
17+
18+
```sh
19+
git clone https://github.com/0xPolygon/agglayer.git
20+
cd agglayer/
21+
```
22+
23+
## Set up and installation
24+
25+
### Local
26+
27+
Run the following command to bring up a zkEVM node, a prover, and a mock L1 network.
28+
29+
```sh
30+
make run-docker
31+
```
32+
33+
### Production
34+
35+
!!! warning
36+
- Currently only one instance of the AggLayer can run at one time.
37+
- The AggLayer should, therefore, automatically start in the case of failure using a containerized setup or an OS level service manager/monitoring system.
38+
39+
Install the Golang dependencies.
40+
41+
```sh
42+
go install .
43+
```
44+
45+
#### Key-signing configurations
46+
47+
Install polygon-cli:
48+
49+
```sh
50+
go install github.com/maticnetwork/polygon-cli@latest
51+
```
52+
53+
Create a new signature:
54+
55+
```sh
56+
polygon-cli signer create --kms GCP --gcp-project-id gcp-project --key-id mykey-tmp
57+
```
58+
59+
Set up ADC in GCloud:
60+
61+
```sh
62+
gcloud auth application-default login
63+
```
64+
65+
In the `../agglayer/docker/data/agglayer.toml` file, add the `KMSKeyName` from GCloud.
66+
67+
## Setting up the AggLayer
68+
69+
Each CDK chain requires a corresponding RPC node configuration that is synced with the target CDK. This node checks the state root after executions of L2 batches.
70+
71+
!!! info "Storage recommendations"
72+
- Use a durable HA PostgresDB for storage; ideally AWS Aurora PostgreSQL or Cloud SQL for PostgreSQL in GCP.
73+
74+
Add the chain configurations to the `../agglayer/docker/data/agglayer.toml` file by amending the following details to add the required chain(s).
75+
76+
* Configure `[FullNodeRPCs]` to point to the corresponding L2 full node.
77+
* Configure `[L1]` to point to the corresponding L1 chain.
78+
* Configure the `[DB]` section with the managed database details.

docs/cdk/resources/third-party-guides.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ hide:
33
- toc
44
---
55

6-
This page is a catalogue of third-party and partner quick starts and guides that explain how to spin up and deploy validium and rollup CDK stacks, and more.
6+
This page links to full guides that some of [our solution providers](https://ecosystem.polygon.technology/spn/explore/?search=&competency=All&chain=All) have developed, including quick starts and guides that explain how to spin up and deploy validium and rollup CDK stacks.
77

88
<div class="grid-container">
99
<div class="grid-item">
@@ -26,3 +26,4 @@ This page is a catalogue of third-party and partner quick starts and guides that
2626
</div>
2727
</div>
2828

29+
Check out the [solution provider page]((https://ecosystem.polygon.technology/spn/explore/?search=&competency=All&chain=All)) to see more info on our partners.

mkdocs.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ nav:
5858
- Quickstart:
5959
- Validium: cdk/get-started/quickstart-validium.md
6060
- Rollup: cdk/get-started/quickstart-rollup.md
61-
- Deploy:
61+
- Deployment tutorials:
6262
- Validium:
6363
- Introduction: cdk/get-started/deploy-validium/intro.md
6464
- Deploy contracts:
@@ -83,12 +83,13 @@ nav:
8383
- Start services: cdk/get-started/deploy-rollup/start-services.md
8484
- Connect to CDK testnet: cdk/get-started/connect-testnet.md
8585
- How to:
86+
- Integrate the AggLayer: cdk/how-to/integrate-agglayer.md
8687
- Quickly test a running stack: cdk/how-to/quick-test-stack.md
8788
- Manage allowlists with policies: cdk/how-to/manage-policies.md
8889
- Use a native token: cdk/how-to/use-native-token.md
8990
- Architecture:
90-
- CDK rollup option: cdk/architecture/cdk-zkevm-option.md
91-
- CDK validium option: cdk/architecture/cdk-validium-option.md
91+
- CDK rollup: cdk/architecture/cdk-zkevm.md
92+
- CDK validium: cdk/architecture/cdk-validium.md
9293
- Specification:
9394
- Validium vs rollup: cdk/spec/validium-vs-rollup.md
9495
- Concepts:

0 commit comments

Comments
 (0)