config

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Aug 5, 2021 License: Apache-2.0, MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConfigComment

func ConfigComment(t interface{}) ([]byte, error)

func FromFile

func FromFile(path string, def interface{}) (interface{}, error)

func FromReader

func FromReader(reader io.Reader, def interface{}) (interface{}, error)

Types

type CommonJourney

type CommonJourney struct {
	// Enabled to enabled or not
	Enabled bool

	// Name registered name
	Name string

	// RoutePath path where the journey will be mounted on the http router
	RoutePath string

	// JourneySecretPath file system path where the journey secret is located
	// authorize requests
	SecretPath string

	// JourneySecretPath file system path where the journey secret is located
	// authorize requests
	ConfigPath string
}

type Config

type Config struct {
	Journeys []CommonJourney
}

func DefaultConfig

func DefaultConfig() *Config

type URL

type URL url.URL

func (URL) MarshalText

func (u URL) MarshalText() ([]byte, error)

func (*URL) UnmarshalText

func (u *URL) UnmarshalText(text []byte) error

UnmarshalText implements interface for TOML decoding

Jump to

Keyboard shortcuts

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