shared

package
v3.10.10 Latest Latest
Warning

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

Go to latest
Published: Feb 15, 2021 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInitializeBaseComponent              = errors.Define("initialize_base_component", "could not initialize base component")
	ErrInitializeIdentityServer             = errors.Define("initialize_identity_server", "could not initialize Identity Server")
	ErrInitializeGatewayServer              = errors.Define("initialize_gateway_server", "could not initialize Gateway Server")
	ErrInitializeNetworkServer              = errors.Define("initialize_network_server", "could not initialize Network Server")
	ErrInitializeApplicationServer          = errors.Define("initialize_application_server", "could not initialize Application Server")
	ErrInitializeJoinServer                 = errors.Define("initialize_join_server", "could not initialize Join Server")
	ErrInitializeConsole                    = errors.Define("initialize_console", "could not initialize Console")
	ErrInitializeGatewayConfigurationServer = errors.Define("initialize_gateway_configuration_server", "could not initialize Gateway Configuration Server")
	ErrInitializeDeviceTemplateConverter    = errors.Define("initialize_device_template_converter", "could not initialize Device Template Converter")
	ErrInitializeQRCodeGenerator            = errors.Define("initialize_qr_code_generator", "could not initialize QR Code Generator")
	ErrInitializePacketBrokerAgent          = errors.Define("initialize_packet_broker_agent", "could not initialize Packet Broker Agent")
)

Errors returned by component initialization.

View Source
var DefaultAssetsBaseURL = DefaultHTTPConfig.Static.Mount

DefaultAssetsBaseURL is the default public URL where the assets are served.

View Source
var DefaultBaseConfig = config.Base{
	Log: DefaultLogConfig,
}

DefaultBaseConfig is the default base component configuration.

View Source
var DefaultBlobConfig = config.BlobConfig{
	Provider: "local",
	Local: config.BlobConfigLocal{
		Directory: "./public/blob",
	},
}

DefaultBlobConfig is the default config for the blob store.

View Source
var DefaultClusterConfig = cluster.Config{}

DefaultClusterConfig is the default cluster configuration.

View Source
var DefaultConsolePublicURL = DefaultPublicURL + "/console"

DefaultConsolePublicURL is the default public URL where the Console is served.

View Source
var DefaultDeviceRepositoryConfig = config.DeviceRepositoryConfig{}

DefaultDeviceRepositoryConfig is the default config to retrieve device blueprints.

View Source
var DefaultEventsConfig = config.Events{
	Backend: "internal",
}

DefaultEventsConfig is the default config for Events.

View Source
var DefaultFrequencyPlansConfig = config.FrequencyPlansConfig{
	URL: "https://raw.githubusercontent.com/TheThingsNetwork/lorawan-frequency-plans/master",
}

DefaultFrequencyPlansConfig is the default config to retrieve frequency plans.

View Source
var DefaultGRPCConfig = config.GRPC{
	Listen:         ":1884",
	ListenTLS:      ":8884",
	TrustedProxies: []string{"127.0.0.0/8", "10.0.0.0/8", "100.64.0.0/10", "172.16.0.0/12", "192.168.0.0/16"},
}

DefaultGRPCConfig is the default config for GRPC.

View Source
var DefaultHTTPConfig = config.HTTP{
	Listen:         ":1885",
	ListenTLS:      ":8885",
	TrustedProxies: []string{"127.0.0.0/8", "10.0.0.0/8", "100.64.0.0/10", "172.16.0.0/12", "192.168.0.0/16"},
	Static: config.HTTPStaticConfig{
		Mount:      "/assets",
		SearchPath: []string{"public", "/srv/ttn-lorawan/public"},
	},
	PProf: config.PProf{
		Enable: true,
	},
	Metrics: config.Metrics{
		Enable: true,
	},
	Health: config.Health{
		Enable: true,
	},
}

DefaultHTTPConfig is the default HTTP config.

View Source
var DefaultInteropServerConfig = config.InteropServer{
	ListenTLS: ":8886",
}

DefaultInteropServerConfig is the default interop server config.

View Source
var DefaultKeyVaultConfig = config.KeyVault{
	Provider: "static",
}

DefaultKeyVaultConfig is the default config for key vaults.

View Source
var DefaultLogConfig = config.Log{
	Level: log.InfoLevel,
}

DefaultLogConfig is the default log configuration.

View Source
var DefaultOAuthPublicURL = DefaultPublicURL + "/oauth"

DefaultOAuthPublicURL is the default public URL where OAuth is served.

View Source
var DefaultPublicHost = "localhost"

DefaultPublicHost is the default public host where The Things Stack is served.

View Source
var DefaultPublicURL = "http://" + DefaultPublicHost + ":1885"

DefaultPublicURL is the default public URL where The Things Stack is served.

View Source
var DefaultRedisConfig = redis.Config{
	Address:       "localhost:6379",
	Database:      0,
	RootNamespace: []string{"ttn", "v3"},
}

DefaultRedisConfig is the default config for Redis.

View Source
var DefaultRightsConfig = config.Rights{
	TTL: 2 * time.Minute,
}

DefaultRightsConfig is the default config to fetch rights from the Identity Server.

DefaultServiceBase is the default base config for a service.

View Source
var DefaultTLSConfig = tlsconfig.Config{
	ServerAuth: tlsconfig.ServerAuth{
		Certificate: "cert.pem",
		Key:         "key.pem",
		ACME: tlsconfig.ACME{
			Endpoint: acme.LetsEncryptURL,
		},
	},
}

DefaultTLSConfig is the default TLS config.

Functions

func InitializeEvents

func InitializeEvents(ctx context.Context, taskStarter component.TaskStarter, conf config.ServiceBase) error

InitializeEvents initializes the event system.

func InitializeFallbacks added in v3.9.2

func InitializeFallbacks(conf *config.ServiceBase) error

Initialize configuration fallbacks.

Types

This section is empty.

Jump to

Keyboard shortcuts

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