Documentation
¶
Index ¶
- Variables
- func GetAddress() string
- func GetBlobFilesDir() string
- func GetConfig() *configWrapper
- func GetInternalAPIHost() string
- func GetLbrynetServers() map[string]string
- func GetPaidTokenPrivKey() string
- func GetPublishSourceDir() string
- func GetReflectorAddress() string
- func GetSentryDSN() string
- func IsProduction() bool
- func NewConfig() *configWrapper
- func Override(key string, value interface{})
- func ProjectRoot() string
- func RestoreOverridden()
- func ShouldLogResponses() bool
- type DBConfig
Constants ¶
This section is empty.
Variables ¶
var Config *configWrapper
Functions ¶
func GetAddress ¶ added in v0.6.3
func GetAddress() string
GetAddress determines address to bind http API server to
func GetBlobFilesDir ¶ added in v0.8.2
func GetBlobFilesDir() string
GetBlobFilesDir returns directory where SDK instance stores blob files.
func GetInternalAPIHost ¶ added in v0.6.3
func GetInternalAPIHost() string
GetInternalAPIHost returns the address of internal-api server
func GetLbrynetServers ¶ added in v0.10.4
GetLbrynetServers returns the names/addresses of every SDK server
func GetPaidTokenPrivKey ¶ added in v0.14.0
func GetPaidTokenPrivKey() string
GetPaidTokenPrivKey returns absolute path to the private RSA key for generating paid tokens
func GetPublishSourceDir ¶ added in v0.8.2
func GetPublishSourceDir() string
GetPublishSourceDir returns directory for storing published files before they're uploaded to lbrynet. The directory needs to be accessed by the running SDK instance.
func GetReflectorAddress ¶ added in v0.8.2
func GetReflectorAddress() string
GetReflectorAddress returns reflector address in the format of host:port.
func GetSentryDSN ¶ added in v0.6.3
func GetSentryDSN() string
GetSentryDSN returns sentry.io service DSN
func IsProduction ¶
func IsProduction() bool
IsProduction is true if we are running in a production environment
func Override ¶
func Override(key string, value interface{})
Override sets a setting key value to whatever you supply. Useful in tests:
config.Override("Lbrynet", "http://www.google.com:8080/api/proxy")
defer config.RestoreOverridden()
...
func ProjectRoot ¶
func ProjectRoot() string
func RestoreOverridden ¶
func RestoreOverridden()
RestoreOverridden restores original v values overridden by Override
func ShouldLogResponses ¶ added in v0.10.0
func ShouldLogResponses() bool
ShouldLogResponses enables or disables full SDK responses logging