Skip to content

Commit

Permalink
feat: add support for Zhejiang and Dockerfile fix
Browse files Browse the repository at this point in the history
  • Loading branch information
infloop committed Feb 15, 2023
1 parent 1e3e1c3 commit a5b633e
Show file tree
Hide file tree
Showing 7 changed files with 17 additions and 11 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ FROM node:14.18.1-alpine3.13 as building

# needed for git dependencies
RUN apk update && apk upgrade && \
apk add --no-cache bash=5.1.16-r0 git=2.30.5-r0 openssh=8.4_p1-r4
apk add --no-cache bash=5.1.16-r0 git=2.30.6-r0 openssh=8.4_p1-r4

RUN mkdir /council

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"@ethersproject/providers": "^5.4.5",
"@lido-nestjs/fetch": "^1.3.1",
"@lido-nestjs/middleware": "^1.1.1",
"@lido-sdk/constants": "^1.2.0",
"@lido-sdk/constants": "^1.8.0",
"@nestjs/common": "^8.0.0",
"@nestjs/config": "^1.0.1",
"@nestjs/core": "^8.0.0",
Expand Down
2 changes: 2 additions & 0 deletions src/bls/bls.constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,11 @@ export const Domain = Bytes32;
export const DOMAIN_DEPOSIT = Uint8Array.from([3, 0, 0, 0]);
export const GENESIS_FORK_VERSION_MAINNET = Version.fromJson('0x00000000');
export const GENESIS_FORK_VERSION_PRATER = Version.fromJson('0x00001020');
export const GENESIS_FORK_VERSION_ZHEJIANG = Version.fromJson('0x00000069');
export const ZERO_HASH = Buffer.alloc(32, 0);

export const GENESIS_FORK_VERSION_BY_CHAIN_ID = {
[CHAINS.Mainnet]: GENESIS_FORK_VERSION_MAINNET,
[CHAINS.Goerli]: GENESIS_FORK_VERSION_PRATER,
[CHAINS.Zhejiang]: GENESIS_FORK_VERSION_ZHEJIANG,
};
1 change: 1 addition & 0 deletions src/contracts/deposit/deposit.constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ export const DEPLOYMENT_BLOCK_NETWORK: {
} = {
[CHAINS.Mainnet]: 11052984,
[CHAINS.Goerli]: 4367322,
[CHAINS.Zhejiang]: 67530,
};

export const getDeploymentBlockByNetwork = (chainId: CHAINS): number => {
Expand Down
2 changes: 2 additions & 0 deletions src/contracts/repository/repository.constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ export const LIDO_BY_NETWORK: {
} = {
[CHAINS.Mainnet]: '0xae7ab96520DE3A18E5e111B5EaAb095312D7fE84',
[CHAINS.Goerli]: '0x1643E812aE58766192Cf7D2Cf9567dF2C37e9B7F',
[CHAINS.Zhejiang]: '0xEC9ac956D7C7fE5a94919fD23BAc4a42f950A403',
};

export const getLidoAddress = (chainId: CHAINS): string => {
Expand All @@ -19,6 +20,7 @@ export const DEPOSIT_SECURITY_BY_NETWORK: {
} = {
[CHAINS.Mainnet]: '0x710B3303fB508a84F10793c1106e32bE873C24cd',
[CHAINS.Goerli]: '0x7DC1C1ff64078f73C98338e2f17D1996ffBb2eDe',
[CHAINS.Zhejiang]: '0x48bEdD13FF63F7Cd4d349233B6a57Bff285f8E32',
};

export const getDepositSecurityAddress = (chainId: CHAINS): string => {
Expand Down
1 change: 1 addition & 0 deletions src/messages/messages.constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ export const MESSAGE_TOPIC_PREFIX_BY_NETWORK: {
} = {
[CHAINS.Mainnet]: 'mainnet',
[CHAINS.Goerli]: 'goerli',
[CHAINS.Zhejiang]: 'testnet',
};

export const getMessageTopicPrefix = (chainId: CHAINS): string => {
Expand Down
18 changes: 9 additions & 9 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1013,12 +1013,12 @@
resolved "https://registry.npmjs.org/@lido-nestjs/middleware/-/middleware-1.1.1.tgz#ffe6cb343f5e81282b70f8746879f3cf506ac3d5"
integrity sha512-0y9e7ydM3NkAhoiiv/tSsBu8KLbvPJ19QPRiAYBy33y8Fv5PPjypA3qAG03ImBQ3qFXAp29ZUrSs18vkACf8Ng==

"@lido-sdk/constants@^1.2.0":
version "1.2.0"
resolved "https://registry.yarnpkg.com/@lido-sdk/constants/-/constants-1.2.0.tgz#e9eb1830f762ff901dd4c27bad2ddfca1335931c"
integrity sha512-PAWXerRFn3/qnaEvPhN+69yCZT1b4KFtJWe1JN3+bLVThYyAkj6zK73HHCCm4idPHl+nustcSMnU15GNUjqZ9A==
"@lido-sdk/constants@^1.8.0":
version "1.8.0"
resolved "https://registry.yarnpkg.com/@lido-sdk/constants/-/constants-1.8.0.tgz#6f0e0c0380c2ca0e4e88e2c6a77cbc087298dee6"
integrity sha512-yLFXMB7Gxe2haDHp73M4QCXBtRun51zjcxfoeebwtZblrPViRpvBCDzVfQjtcU0sPQ4D4Xs07RhRlFul9x6SBw==
dependencies:
tiny-invariant "1"
tiny-invariant "^1.1.0"

"@nestjs/cli@^8.2.5":
version "8.2.5"
Expand Down Expand Up @@ -5886,10 +5886,10 @@ timers-ext@^0.1.7:
es5-ext "~0.10.46"
next-tick "1"

tiny-invariant@1:
version "1.1.0"
resolved "https://registry.yarnpkg.com/tiny-invariant/-/tiny-invariant-1.1.0.tgz#634c5f8efdc27714b7f386c35e6760991d230875"
integrity sha512-ytxQvrb1cPc9WBEI/HSeYYoGD0kWnGEOR8RY6KomWLBVhqz0RgTwVO9dLrGz7dC+nN9llyI7OKAgRq8Vq4ZBSw==
tiny-invariant@^1.1.0:
version "1.3.1"
resolved "https://registry.yarnpkg.com/tiny-invariant/-/tiny-invariant-1.3.1.tgz#8560808c916ef02ecfd55e66090df23a4b7aa642"
integrity sha512-AD5ih2NlSssTCwsMznbvwMZpJ1cbhkGd2uueNxzv2jDlEeZdU04JQfRnggJQ8DrcVBGjAsCKwFBbDlVNtEMlzw==

tmp@^0.0.33:
version "0.0.33"
Expand Down

0 comments on commit a5b633e

Please sign in to comment.