ttkg

package
v3.33.0 Latest Latest
Warning

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

Go to latest
Published: Dec 18, 2024 License: Apache-2.0 Imports: 20 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 {
	Default struct {
		UpdateChannel string `name:"update-channel" description:"The default update channel that the gateways should use"`
		MQTTServer    string `name:"mqtt-server" description:"The default MQTT server that the gateways should use"`
		FirmwareURL   string `name:"firmware-url" description:"The default URL to the firmware storage"`
	} `name:"default" description:"Default gateway settings"`
}

Config is the configuration for The Things Kickstarter Gateway.

type Option

type Option func(s *Server)

Option configures the Server.

func WithAuth

func WithAuth(auth func(ctx context.Context) grpc.CallOption) Option

WithAuth overrides the Server's auth func.

func WithConfig

func WithConfig(config Config) Option

WithConfig overrides the Server's configuration for The Things Gateway.

func WithRegistry

func WithRegistry(registry ttnpb.GatewayRegistryClient) Option

WithRegistry overrides the Server's gateway registry.

type Server

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

Server implements the CUPS endpoints used by The Things Gateway.

func New

func New(c *component.Component, options ...Option) *Server

New returns a new v2 GCS on top of the given gateway registry.

func (*Server) RegisterRoutes

func (s *Server) RegisterRoutes(server *web.Server)

RegisterRoutes implements the web.Registerer interface.

Jump to

Keyboard shortcuts

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