config

package
v0.0.5 Latest Latest
Warning

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

Go to latest
Published: Nov 22, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const CName = "config"

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Drpc    rpc.Config           `yaml:"drpc"`
	Log     logger.Config        `yaml:"log"`
	Account commonaccount.Config `yaml:"account"`
	// TODO: required somehow
	NetworkStorePath string                 `yaml:"networkStorePath"`
	Network          nodeconf.Configuration `yaml:"network"`
	Quic             quic.Config            `yaml:"quic"`
	Yamux            yamux.Config           `yaml:"yamux"`
	Mongo            Mongo                  `yaml:"mongo"`
	Stripe           Stripe                 `yaml:"stripe"`
	Metric           metric.Config          `yaml:"metric"`
}

func NewFromFile

func NewFromFile(path string) (c *Config, err error)

func (*Config) GetAccount

func (c *Config) GetAccount() commonaccount.Config

func (*Config) GetDrpc

func (c *Config) GetDrpc() rpc.Config

func (*Config) GetMetric added in v0.0.3

func (c *Config) GetMetric() metric.Config

func (*Config) GetNodeConf

func (c *Config) GetNodeConf() nodeconf.Configuration

func (*Config) GetNodeConfStorePath

func (c *Config) GetNodeConfStorePath() string

func (*Config) GetQuic

func (c *Config) GetQuic() quic.Config

func (*Config) GetYamux

func (c *Config) GetYamux() yamux.Config

func (*Config) Init

func (c *Config) Init(a *app.App) (err error)

func (*Config) Name

func (c *Config) Name() (name string)

type Mongo

type Mongo struct {
	Connect    string `yaml:"connect"`
	Database   string `yaml:"database"`
	Collection string `yaml:"collection"`
}

type Stripe

type Stripe struct {
	ApiKey                  string `yaml:"apiKey"`
	WebhooksHttpPort        uint16 `yaml:"webhooksHttpPort"`
	WebhooksSecret          string `yaml:"webhooksSecret"`
	RunWebhooksServer       bool   `yaml:"runWebhooksServer"`
	UseNameService          bool   `yaml:"useNameService"`
	NameserviceAdminPeerKey string `yaml:"nameserviceAdminPeerKey"`
}

Jump to

Keyboard shortcuts

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