config

package
v0.0.0-...-934465a Latest Latest
Warning

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

Go to latest
Published: Jan 7, 2016 License: MIT Imports: 4 Imported by: 0

Documentation

Overview

Package config parses configurations used by other components.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Locals  []Local
	Servers []Server
}

Config contains configurations for local and remote server.

func Parse

func Parse(content []byte) (*Config, error)

Parse parses TOML formatted configrations from content.

type Local

type Local struct {
	Listen  *netaddr.Address
	Remote  Remote
	Timeout time.Duration
}

Local specifies a endpoint running at local to proxy incoming traffic through remote.

type Remote

type Remote struct {
	Address    *netaddr.Address
	Password   string
	Encryption string
}

Remote specifies a remote endpoint and its encryption scheme.

type Server

type Server struct {
	Listen     *netaddr.Address
	Password   string
	Encryption string
	Timeout    time.Duration
}

Server specifies a end point run at remote to proxy incoming traffic to destination.

Jump to

Keyboard shortcuts

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