config

package
v0.0.0-...-7d5229d Latest Latest
Warning

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

Go to latest
Published: Oct 18, 2019 License: MIT Imports: 13 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 {
	RootDir        string
	LogFile        string             `yaml:"log_file"`
	LogFormat      string             `yaml:"log_format"`
	GitlabUrl      string             `yaml:"gitlab_url"`
	GitlabTracing  string             `yaml:"gitlab_tracing"`
	SecretFilePath string             `yaml:"secret_file"`
	Secret         string             `yaml:"secret"`
	HttpSettings   HttpSettingsConfig `yaml:"http_settings"`
	HttpClient     *HttpClient
}

func New

func New() (*Config, error)

func NewFromDir

func NewFromDir(dir string) (*Config, error)

func (*Config) GetHttpClient

func (c *Config) GetHttpClient() *HttpClient

type HttpClient

type HttpClient struct {
	HttpClient *http.Client
	Host       string
}

type HttpSettingsConfig

type HttpSettingsConfig struct {
	User               string `yaml:"user"`
	Password           string `yaml:"password"`
	ReadTimeoutSeconds uint64 `yaml:"read_timeout"`
	CaFile             string `yaml:"ca_file"`
	CaPath             string `yaml:"ca_path"`
	SelfSignedCert     bool   `yaml:"self_signed_cert"`
}

Jump to

Keyboard shortcuts

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