custom

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var UNSETABLE_KEYS = map[string]string{
	"client_max_body_size":  "100m",
	"proxy_connect_timeout": "5s",
	"proxy_buffer_size":     "256k",
	"proxy_buffers":         "4 256k",
	"proxy_http_version":    "1.1",
	"proxy_cookie_domain":   "off",
	"proxy_cookie_path":     "off",
	"port_in_redirect":      "off",
}

如下参数在 nginx-template 中有全局设置,因此不能在 cunstom 中再次设置

Functions

This section is empty.

Types

type Policy

type Policy struct {
	apipolicy.BasePolicy
}

func (Policy) CreateDefaultConfig

func (policy Policy) CreateDefaultConfig(gatewayProvider string, ctx map[string]interface{}) apipolicy.PolicyDto

func (Policy) ParseConfig

func (policy Policy) ParseConfig(dto apipolicy.PolicyDto, ctx map[string]interface{}, forValidate bool) (apipolicy.PolicyConfig, error)

func (Policy) UnmarshalConfig

func (policy Policy) UnmarshalConfig(config []byte, gatewayProvider string) (apipolicy.PolicyDto, error, string)

type PolicyDto

type PolicyDto struct {
	apipolicy.BaseDto
	Config string `json:"config"`
}

func (PolicyDto) IsValidDto

func (dto PolicyDto) IsValidDto(gatewayProvider string) (bool, string)

Jump to

Keyboard shortcuts

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