deploydestruct

package
v1.1.13 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 26, 2025 License: MIT Imports: 16 Imported by: 0

README

Self-Destruct Deployments

Deploy contracts that immediately self-destruct after deployment.

Usage

spamoor deploy-destruct [flags]

Configuration

Base Settings (required)
  • --privkey - Private key of the sending wallet
  • --rpchost - RPC endpoint(s) to send transactions to
Volume Control (either -c or -t required)
  • -c, --count - Total number of transactions to send
  • -t, --throughput - Transactions to send per slot
  • --max-pending - Maximum number of pending transactions
Transaction Settings
  • --basefee - Max fee per gas in gwei (default: 20)
  • --tipfee - Max tip per gas in gwei (default: 2)
  • --gaslimit - Gas limit for each deployment in gwei (default: 10000000)
  • --amount - Transfer amount per transaction in gwei (default: 20)
  • --random-amount - Use random amounts (with --amount as limit)
  • --rebroadcast - Seconds to wait before rebroadcasting (default: 120)
Wallet Management
  • --max-wallets - Maximum number of child wallets to use
  • --refill-amount - ETH amount to fund each child wallet (default: 5)
  • --refill-balance - Minimum ETH balance before refilling (default: 2)
  • --refill-interval - Seconds between balance checks (default: 300)
Client Settings
  • --client-group - Client group to use for sending transactions
  • --deploy-client-group - Client group to use for deployment transactions (same as --client-group if empty)
Debug Options
  • -v, --verbose - Enable verbose output
  • --log-txs - Log all submitted transactions
  • --trace - Enable tracing output

Example

Deploy 100 self-destructing contracts:

spamoor deploy-destruct -p "<PRIVKEY>" -h http://rpc-host:8545 -c 100

Deploy 3 self-destructing contracts per slot:

spamoor deploy-destruct -p "<PRIVKEY>" -h http://rpc-host:8545 -t 3

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ScenarioDefaultOptions = ScenarioOptions{
	TotalCount:        0,
	Throughput:        10,
	MaxPending:        0,
	MaxWallets:        0,
	Rebroadcast:       1,
	BaseFee:           20,
	TipFee:            2,
	Amount:            20,
	GasLimit:          10000000,
	RandomAmount:      false,
	Timeout:           "",
	ClientGroup:       "",
	DeployClientGroup: "",
	LogTxs:            false,
}
View Source
var ScenarioDescriptor = scenario.Descriptor{
	Name:           ScenarioName,
	Description:    "Send deploy and destruct transactions",
	DefaultOptions: ScenarioDefaultOptions,
	NewScenario:    newScenario,
}
View Source
var ScenarioName = "deploy-destruct"

Functions

This section is empty.

Types

type Scenario

type Scenario struct {
	// contains filtered or unexported fields
}

func (*Scenario) Flags

func (s *Scenario) Flags(flags *pflag.FlagSet) error

func (*Scenario) Init

func (s *Scenario) Init(options *scenario.Options) error

func (*Scenario) Run

func (s *Scenario) Run(ctx context.Context) error

type ScenarioOptions

type ScenarioOptions struct {
	TotalCount        uint64  `yaml:"total_count"`
	Throughput        uint64  `yaml:"throughput"`
	MaxPending        uint64  `yaml:"max_pending"`
	MaxWallets        uint64  `yaml:"max_wallets"`
	Rebroadcast       uint64  `yaml:"rebroadcast"`
	BaseFee           float64 `yaml:"base_fee"`
	TipFee            float64 `yaml:"tip_fee"`
	Amount            uint64  `yaml:"amount"`
	GasLimit          uint64  `yaml:"gas_limit"`
	RandomAmount      bool    `yaml:"random_amount"`
	Timeout           string  `yaml:"timeout"`
	ClientGroup       string  `yaml:"client_group"`
	DeployClientGroup string  `yaml:"deploy_client_group"`
	LogTxs            bool    `yaml:"log_txs"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL