proxy

package
v0.23.0 Latest Latest
Warning

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

Go to latest
Published: Oct 28, 2015 License: Apache-2.0 Imports: 24 Imported by: 0

Documentation

Overview

Note: inspiration for this from https://gist.github.com/cespare/3985516

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParsePublicKey

func ParsePublicKey(keyFile string) (interface{}, error)

func ParsePublicKeyFromMemory

func ParsePublicKeyFromMemory(keyFileContents string) (interface{}, error)

Types

type BackendHandler

type BackendHandler struct {
	// contains filtered or unexported fields
}

func (*BackendHandler) ServeHTTP

func (h *BackendHandler) ServeHTTP(rw http.ResponseWriter, req *http.Request)

type Config

type Config struct {
	PublicKey            interface{}
	ListenAddr           string
	CattleAddr           string
	ParentPid            int
	ProxyProtoHttpsPorts map[int]bool
}

func GetConfig

func GetConfig() (*Config, error)

type FrontendHandler

type FrontendHandler struct {
	// contains filtered or unexported fields
}

func (*FrontendHandler) ServeHTTP

func (h *FrontendHandler) ServeHTTP(rw http.ResponseWriter, req *http.Request)

type ProxyStarter

type ProxyStarter struct {
	BackendPaths       []string
	FrontendPaths      []string
	StatsPaths         []string
	CattleProxyPaths   []string
	CattleWSProxyPaths []string
	Config             *Config
}

func (*ProxyStarter) StartProxy

func (s *ProxyStarter) StartProxy() error

type StatsHandler

type StatsHandler struct {
	// contains filtered or unexported fields
}

func (*StatsHandler) ServeHTTP

func (h *StatsHandler) ServeHTTP(rw http.ResponseWriter, req *http.Request)

Directories

Path Synopsis
This code is adapted from: https://github.com/armon/go-proxyproto The MIT License (MIT) Copyright (c) 2014 Armon Dadgar Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
This code is adapted from: https://github.com/armon/go-proxyproto The MIT License (MIT) Copyright (c) 2014 Armon Dadgar Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

Jump to

Keyboard shortcuts

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