Documentation ¶
Index ¶
- Constants
- Variables
- func BaseCLIFlags(envPrefix string) []cli.Flag
- func DefaultSecretsConfigAsString() string
- func ForkCLIFlags(envPrefix string) []cli.Flag
- func OPChainByName(superchain *registry.Superchain, name string) *registry.ChainConfig
- func PrintDocLinks()
- type CLIConfig
- type Chain
- type ChainConfig
- type ForkCLIConfig
- type ForkConfig
- type L2Config
- type NetworkConfig
- type SecretsConfig
Constants ¶
View Source
const ( ForkCommandName = "fork" DocsCommandName = "docs" AdminPortFlagName = "admin.port" L1ForkHeightFlagName = "l1.fork.height" L1PortFlagName = "l1.port" L1HostFlagName = "l1.host" ChainsFlagName = "chains" NetworkFlagName = "network" L2StartingPortFlagName = "l2.starting.port" L2HostFlagName = "l2.host" LogsDirectoryFlagName = "logs.directory" InteropEnabledFlagName = "interop.enabled" InteropAutoRelayFlagName = "interop.autorelay" InteropDelayFlagName = "interop.delay" OdysseyEnabledFlagName = "odyssey.enabled" )
Variables ¶
View Source
var ( DefaultSecretsConfig = SecretsConfig{ Accounts: 10, Mnemonic: "test test test test test test test test test test test junk", DerivationPath: accounts.DefaultRootDerivationPath, } )
Functions ¶
func BaseCLIFlags ¶
func BaseCLIFlags(envPrefix string) []cli.Flag
func DefaultSecretsConfigAsString ¶
func DefaultSecretsConfigAsString() string
Note: The default secrets config is used everywhere
func ForkCLIFlags ¶
func ForkCLIFlags(envPrefix string) []cli.Flag
func OPChainByName ¶
func OPChainByName(superchain *registry.Superchain, name string) *registry.ChainConfig
func PrintDocLinks ¶
func PrintDocLinks()
Types ¶
type CLIConfig ¶
type CLIConfig struct { AdminPort uint64 L1Port uint64 L2StartingPort uint64 InteropAutoRelay bool InteropDelay uint64 OdysseyEnabled bool LogsDirectory string ForkConfig *ForkCLIConfig L1Host string L2Host string }
func ReadCLIConfig ¶
type Chain ¶
type Chain interface { // Properties Endpoint() string LogPath() string Config() *ChainConfig EthClient() *ethclient.Client // Additional methods SimulatedLogs(ctx context.Context, tx *types.Transaction) ([]types.Log, error) SetCode(ctx context.Context, result interface{}, address common.Address, code string) error SetStorageAt(ctx context.Context, result interface{}, address common.Address, storageSlot string, storageValue string) error SetBalance(ctx context.Context, result interface{}, address common.Address, value *big.Int) error SetIntervalMining(ctx context.Context, result interface{}, interval int64) error // Lifecycle Start(ctx context.Context) error Stop(ctx context.Context) error }
type ChainConfig ¶
type ChainConfig struct { Name string Host string Port uint64 ChainID uint64 GenesisJSON []byte SecretsConfig SecretsConfig // Optional Config ForkConfig *ForkConfig // Optional Config (L1 chain if nil) L2Config *L2Config // Optional StartingTimestamp uint64 // Optional LogsDirectory string // Optional OdysseyEnabled bool }
type ForkCLIConfig ¶
type ForkConfig ¶
type L2Config ¶
type L2Config struct { L1ChainID uint64 L1Addresses *registry.AddressList DependencySet []uint64 }
type NetworkConfig ¶
type NetworkConfig struct { L1Config ChainConfig L2StartingPort uint64 L2Configs []ChainConfig // Signaled higher up as a way to generally // check if Interop is enabled InteropEnabled bool InteropAutoRelay bool InteropDelay uint64 }
func GetDefaultNetworkConfig ¶
func GetDefaultNetworkConfig(startingTimestamp uint64, logsDirectory string) NetworkConfig
type SecretsConfig ¶
type SecretsConfig struct { Accounts uint64 Mnemonic string DerivationPath accounts.DerivationPath }
Click to show internal directories.
Click to hide internal directories.