config

package
v0.0.0-...-cc86588 Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2019 License: AGPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultPort       = "8040"
	DefaultDriver     = "memory"
	DefaultDataSource = ""
	DefaultMQTTURL    = "mqtt.example.com"
	DefaultMQTTPort   = "8883"
	DefaultCertsPath  = "certs"
	DefaultConfigPath = "certs"
)

Default settings

Variables

This section is empty.

Functions

This section is empty.

Types

type MQTTConnect

type MQTTConnect struct {
	ClientID   string
	RootCA     []byte
	ClientCert []byte
	ClientKey  []byte
}

MQTTConnect holds the credentials for MQTT connection

type Settings

type Settings struct {
	Port        string
	Driver      string
	DataSource  string
	MQTTUrl     string
	MQTTPort    string
	KeySecret   string
	MQTTConnect MQTTConnect
}

Settings defines the application configuration

func ParseArgs

func ParseArgs() *Settings

ParseArgs checks the command line arguments

func TestConfig

func TestConfig() *Settings

TestConfig creates config settings for testing

Jump to

Keyboard shortcuts

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