Skip to content

Commit 98bce39

Browse files
committed
update sdk to support contracts verification
1 parent c34d85b commit 98bce39

File tree

7 files changed

+55
-4
lines changed

7 files changed

+55
-4
lines changed

public/locales/en/translation.json

+1
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,7 @@
171171
"customizingSdkComponents": "Customizing SDK Components",
172172
"awsDeployment": "AWS Deployment",
173173
"operation": "Operating a Chain",
174+
"contractsVerification": "Contracts Verification",
174175
"gasAndFees": "Gas & Fee Management",
175176
"monitoring": "Monitoring",
176177
"security": "Security and Recovery",

src/config/sidebar.ts

+4
Original file line numberDiff line numberDiff line change
@@ -411,6 +411,10 @@ export const getSidebar = () => {
411411
{
412412
section: t("sidebar.sdk.operation"),
413413
contents: [
414+
{
415+
title: t("sidebar.sdk.contractsVerification"),
416+
url: formatUrl("sdk/operation/contracts-verification"),
417+
},
414418
{
415419
title: t("sidebar.sdk.gasAndFees"),
416420
url: formatUrl("sdk/operation/gas-and-fees"),

src/content/docs/en/sdk/guides/aws-deployment.mdx

+1-1
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ Make sure to follow the installation instructions for each tool on their respect
5858
To install the scroll-sdk-cli, run:
5959

6060
```bash
61-
npm install -g @scroll-tech/scroll-sdk-cli
61+
npm install -g @scroll-tech/scroll-sdk-cli@0.1.1
6262
```
6363

6464
{/* TODO: Replace with new command */}

src/content/docs/en/sdk/guides/devnet-deployment.mdx

+2-2
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ As we migrate to the Blockscout upgrade with native Scroll SDK support, we haven
6464
- `brew install nvm`
6565
- `nvm install node`
6666
- scroll-sdk-cli *(Experimental, APIs may change)*
67-
- `npm install -g @scroll-tech/scroll-sdk-cli`
67+
- `npm install -g @scroll-tech/scroll-sdk-cli@0.1.1`
6868
3. You should now be able to open a terminal and run the following:
6969
- `docker -v`
7070
- `kubectl version`
@@ -125,7 +125,7 @@ As we migrate to the Blockscout upgrade with native Scroll SDK support, we haven
125125
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.1/install.sh | bash
126126
# Re-login or source your shell configuration
127127
nvm install 20
128-
npm install -g @scroll-tech/scroll-sdk-cli
128+
npm install -g @scroll-tech/scroll-sdk-cli@0.1.1
129129
```
130130
{/* TODO: Update the cli command to use the new `scrollsdk` install command */}
131131

src/content/docs/en/sdk/guides/digital-ocean-alt-gas-token.mdx

+1-1
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ Please be aware that Blockscout will take a few extra steps to setup without aut
6363
- k9s *(optional)*
6464

6565

66-
To install the scroll-sdk-cli, run `npm install -g @scroll-tech/scroll-sdk-cli`
66+
To install the scroll-sdk-cli, run `npm install -g @scroll-tech/scroll-sdk-cli@0.1.1`
6767

6868
Then, run `scrollsdk test dependencies` to test that the tool works and to check the required dependencies listed above.
6969

Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
---
2+
section: sdk
3+
title: "Upgrading Scroll SDK"
4+
lang: "en"
5+
permalink: "sdk/operation/contracts-verification"
6+
excerpt: "Learn more about verify smart contract scource code on blockchain explorer"
7+
---
8+
9+
import Steps from '../../../../../components/Steps/Steps.astro';
10+
11+
## Overview
12+
13+
This guide documents how to verify the smart contract source code of your own Scroll SDK deployment on blockchain explorers.
14+
15+
### Devnet deployment
16+
17+
<Steps>
18+
1. Go to the `devnet` folder of `scroll-sdk` repository
19+
2. Configurate `[contracts.verification]` section of your config.toml file as described [here](/en/sdk/technical-stack/configuration#contracts-verification)
20+
3. To start the verification process, run the following command:
21+
- `make verify`
22+
</Steps>
23+
24+
### Production deployment
25+
26+
<Steps>
27+
1. Go to the root directory of your local workspace repo
28+
2. Configurate `[contracts.verification]` section of your config.toml file as described [here](/en/sdk/technical-stack/configuration#contracts-verification)
29+
3. To start the verification process, run the following command:
30+
- `scrollsdk setup verify-contracts`
31+
</Steps>

src/content/docs/en/sdk/technical-stack/configuration.mdx

+15
Original file line numberDiff line numberDiff line change
@@ -179,6 +179,21 @@ Contained in the `[contracts.overrides]` section.
179179
| L2_WETH | Override address for the L2 WETH contract. | `0x5300000000000000000000000000000000000004` |
180180
| L2_TX_FEE_VAULT | Override address for the L2 transaction fee vault contract. | `0x5300000000000000000000000000000000000005` |
181181

182+
### Contracts Verification
183+
184+
Contained in the `[contracts.verification]` section.
185+
186+
| Config Variable | Description | Default Value |
187+
|-----------------|-------------|---------------|
188+
| VERIFIER_TYPE_L1 | Verifier type for the L1 contracts. supports `blockscout`, `etherscan` and `sourcify`. | `blockscout` |
189+
| VERIFIER_TYPE_L2 | Verifier type for the L2 contracts. supports `blockscout`, `etherscan` and `sourcify`. | `blockscout` |
190+
| EXPLORER_URI_L1 | Homepage URL of L1 explorer. | `http://l1-explorer.scrollsdk` |
191+
| EXPLORER_URI_L2 | Homepage URL of L2 explorer. | `http://blockscout.scrollsdk` |
192+
| RPC_URI_L1 | RPC URL of L1 network. | `http://l1-devnet.scrollsdk` |
193+
| RPC_URI_L2 | RPC URL of L1 network. | `http://l1-devnet.scrollsdk` |
194+
| EXPLORER_API_KEY_L1 | Explorer API key for L1 contracts verification. Leave it blank if verifier type is `blockscout`. | |
195+
| EXPLORER_API_KEY_L2 | Explorer API key for L2 contracts verification. Leave it blank if verifier type is `blockscout`. | |
196+
182197
### Coordinator
183198

184199
Contained in the `[coordinator]` section.

0 commit comments

Comments
 (0)