config

package
v0.0.0-...-ea4b12c Latest Latest
Warning

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

Go to latest
Published: Oct 31, 2021 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// Svc is a global assets
	Svc []Service
)

Functions

This section is empty.

Types

type Proxy

type Proxy struct {
	Src    string
	Target []Target
}

Proxy is a struct (unmarshal from config.file)

func (*Proxy) Unmarshal

func (p *Proxy) Unmarshal(res gjson.Result)

Unmarshal is to implement method in interface "Unmarshaler"

type Service

type Service struct {
	Listen  uint16
	Log     string
	Static  string
	Proxies []Proxy
}

Service is a struct (unmarshal from config.json)

func (*Service) Unmarshal

func (s *Service) Unmarshal(res gjson.Result)

Unmarshal is to implement method in interface "Unmarshaler"

type Target

type Target struct {
	Dst    string
	Weight int
}

Target is a struct (unmarshal from config.file)

func (*Target) Unmarshal

func (t *Target) Unmarshal(res gjson.Result)

Unmarshal is to implement method in interface "Unmarshaler"

Jump to

Keyboard shortcuts

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