config

package
v0.0.0-...-bc9f93a Latest Latest
Warning

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

Go to latest
Published: Dec 22, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Indexer   IndexerConfig
	Reward    RewardConfig
	Submit    SubmitConfig
	TxBuilder TxBuilderConfig
	Wallet    WalletConfig
	Network   string `envconfig:"NETWORK"`
}

func GetConfig

func GetConfig() *Config

GetConfig returns the global config instance

func Load

func Load() (*Config, error)

type IndexerConfig

type IndexerConfig struct {
	Address    string `envconfig:"INDEXER_TCP_ADDRESS"`
	SocketPath string `envconfig:"INDEXER_SOCKET_PATH"`
}

type RewardConfig

type RewardConfig struct {
	MinLovelace   uint64 `envconfig:"MIN_LOVELACE"`
	RewardAddress string `envconfig:"REWARD_ADDRESS"`
	RewardAmount  uint64 `envconfig:"REWARD_AMOUNT"`
	SourceAddress string `envconfig:"SOURCE_ADDRESS"`
}

type SubmitConfig

type SubmitConfig struct {
	Address    string `envconfig:"SUBMIT_TCP_ADDRESS"`
	SocketPath string `envconfig:"SUBMIT_SOCKET_PATH"`
	Url        string `envconfig:"SUBMIT_URL"`
}

type TxBuilderConfig

type TxBuilderConfig struct {
	BlockfrostApiKey string `envconfig:"BLOCKFROST_API_KEY"`
	KupoUrl          string `envconfig:"KUPO_URL"`
}

type WalletConfig

type WalletConfig struct {
	Mnemonic string `envconfig:"MNEMONIC"`
}

Jump to

Keyboard shortcuts

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