Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix asset signer tool #239

Merged
merged 4 commits into from
Aug 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion etherman/etherman_xlayer.go
Original file line number Diff line number Diff line change
Expand Up @@ -281,7 +281,7 @@ func NewClient(cfg Config, l1Config L1Config) (*Client, error) {
// Get RollupID
rollupID, err := rollupManager.RollupAddressToID(&bind.CallOpts{Pending: false}, l1Config.ZkEVMAddr)
if err != nil {
log.Debugf("error rollupManager.RollupAddressToID(%s). Error: %w", l1Config.RollupManagerAddr, err)
log.Debugf("error rollupManager.RollupAddressToID(%s). Error: %w", l1Config.ZkEVMAddr, err)
return nil, err
}
log.Debug("rollupID: ", rollupID)
Expand Down
4 changes: 2 additions & 2 deletions test/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -775,7 +775,7 @@ services:
xlayer-signer:
container_name: xlayer-signer
restart: unless-stopped
image: xlayer-signer
image: giskook/xlayer-signer:0001
ports:
- 7001:7001
volumes:
Expand Down Expand Up @@ -887,4 +887,4 @@ services:
- ENABLE_DEPOSIT_WARNING=true
- ENABLE_REPORT_FORM=false
- USE_FIAT_EXCHANGE_RATES=false
- SHOW_OUTDATED_NETWORK_MODAL=false
- SHOW_OUTDATED_NETWORK_MODAL=false
9 changes: 5 additions & 4 deletions tools/signer/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,11 @@ type L1 struct {
SeqPrivateKey types.KeystoreFileConfig `mapstructure:"SeqPrivateKey"`
AggPrivateKey types.KeystoreFileConfig `mapstructure:"AggPrivateKey"`

PolygonMaticAddress common.Address `mapstructure:"PolygonMaticAddress"`
GlobalExitRootManagerAddr common.Address `mapstructure:"GlobalExitRootManagerAddress"`
DataCommitteeAddr common.Address `mapstructure:"DataCommitteeAddress"`
PolygonZkEVMAddress common.Address `mapstructure:"PolygonZkEVMAddress"`
PolygonMaticAddress common.Address `mapstructure:"PolygonMaticAddress"`
GlobalExitRootManagerAddr common.Address `mapstructure:"GlobalExitRootManagerAddress"`
DataCommitteeAddr common.Address `mapstructure:"DataCommitteeAddress"`
PolygonZkEVMAddress common.Address `mapstructure:"PolygonZkEVMAddress"`
PolygonRollupManagerAddress common.Address `mapstructure:"PolygonRollupManagerAddress"`
}

// Config is the configuration for the tool
Expand Down
2 changes: 2 additions & 0 deletions tools/signer/service/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -66,10 +66,12 @@ func NewServer(cfg *config.Config, ctx context.Context) *Server {
ZkEVMAddr: cfg.L1.PolygonZkEVMAddress,
PolAddr: cfg.L1.PolygonMaticAddress,
GlobalExitRootManagerAddr: cfg.L1.GlobalExitRootManagerAddr,
RollupManagerAddr: cfg.L1.PolygonRollupManagerAddress,
}

var err error
srv.ethClient, err = etherman.NewClient(srv.ethCfg, srv.l1Cfg)
log.Infof("url: %v, l1 chain id: %v, zkevm addr: %v, rollup manager addr: %v", srv.ethCfg.URL, srv.l1Cfg.L1ChainID, srv.l1Cfg.ZkEVMAddr, srv.l1Cfg.RollupManagerAddr)
if err != nil {
log.Fatal("error creating etherman client. Error: %v", err)
}
Expand Down
Loading