config

package
v0.0.0-...-bf40b24 Latest Latest
Warning

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

Go to latest
Published: Aug 23, 2022 License: ISC Imports: 5 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 {
	Service        ServiceCfg       `mapstructure:"service"`
	ContentCfg     ContentSvcConfig `mapstructure:"content"`
	ManagerCfg     ManagerSvcConfig `mapstructure:"manager"`
	Loadbalancer   LoadbalancerCfg  `mapstructure:"loadbalancer"`
	Postgres       PostgresCfg      `mapstructure:"postgres"`
	TracerProvider TracerProvider   `mapstructure:"tracer"`
}

Config The root config structure for the provisioner service

func InitConfig

func InitConfig(ctx context.Context, relPath string) Config

InitConfig initialise the config from a config file

type ContentSvcConfig

type ContentSvcConfig struct {
	Port string `mapstructure:"port"`
	Host string `mapstructure:"host"`
}

ContentSvcConfig config to allow the provisioner to make calls to the content service

type LoadbalancerCfg

type LoadbalancerCfg struct {
	Domain   string `mapstructure:"domain"`
	JoinSlug string `mapstructure:"join-slug"`
}

LoadbalancerCfg config to tell the provisioner about the loadbalancer

type ManagerSvcConfig

type ManagerSvcConfig struct {
	Port string `mapstructure:"port"`
	Host string `mapstructure:"host"`
}

ManagerSvcConfig config to allow the provisioner to make calls to the manager service

type PostgresCfg

type PostgresCfg struct {
	Host     string `mapstructure:"host"`
	Port     string `mapstructure:"port"`
	User     string `mapstructure:"user"`
	Password string `mapstructure:"password"`
	DBName   string `mapstructure:"dbname"`
}

PostgresCfg config to allow the service to access postgres

type ServiceCfg

type ServiceCfg struct {
	Port string `mapstructure:"port"`
	Host string `mapstructure:"host"`
}

ServiceCfg Configuration specific to the provisioner service

type TracerProvider

type TracerProvider struct {
	URL string `mapstructure:"url"`
}

Jump to

Keyboard shortcuts

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