config

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Aug 13, 2023 License: MIT Imports: 4 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 {
	BindingAddr string       `required:"false" envconfig:"BINDING_ADDRESS"`
	Debug       bool         `required:"false" envconfig:"DEBUG"`
	Credentials []credential `required:"false" envconfig:"CREDENTIALS"`

	RequestHeaderPrefix         string `required:"false" envconfig:"REQUEST_HEADER_PREFIX"`
	ForwardRequestHeaderPrefix  string `required:"false" envconfig:"FORWARD_REQUEST_HEADER_PREFIX"`
	ForwardResponseHeaderPrefix string `required:"false" envconfig:"FORWARD_RESPONSE_HEADER_PREFIX"`
	ForwardResponseStatusHeader string `required:"false" envconfig:"FORWARD_RESPONSE_STATUS_HEADER"`

	CorsAllowOrigin  []string `required:"false" envconfig:"CORS_ALLOW_ORIGIN"`
	CorsAllowMethods []string `required:"false" envconfig:"CORS_ALLOW_METHODS"`
	CorsAllowHeaders []string `required:"false" envconfig:"CORS_ALLOW_HEADERS"`
	CorsAllowMaxAge  int      `required:"false" envconfig:"CORS_ALLOW_MAX_AGE"`
}

func ReadConfig

func ReadConfig() (*Config, error)

Jump to

Keyboard shortcuts

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