models

package
v0.4.2 Latest Latest
Warning

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

Go to latest
Published: Nov 4, 2022 License: MulanPSL-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (

	// EndpointModeTCP captures enum value "tcp"
	EndpointModeTCP string = "tcp"

	// EndpointModeUDP captures enum value "udp"
	EndpointModeUDP string = "udp"

	// EndpointModeHTTP captures enum value "http"
	EndpointModeHTTP string = "http"
)
View Source
const (

	// EndpointBackendCheckCommandsCheckTypeHTTPDashCheck captures enum value "http-check"
	EndpointBackendCheckCommandsCheckTypeHTTPDashCheck string = "http-check"

	// EndpointBackendCheckCommandsCheckTypeTCPDashCheck captures enum value "tcp-check"
	EndpointBackendCheckCommandsCheckTypeTCPDashCheck string = "tcp-check"
)
View Source
const (

	// EndpointFrontendSslOptionsVerifyRequired captures enum value "required"
	EndpointFrontendSslOptionsVerifyRequired string = "required"

	// EndpointFrontendSslOptionsVerifyOptional captures enum value "optional"
	EndpointFrontendSslOptionsVerifyOptional string = "optional"
)
View Source
const (

	// BackendServerCheckSslOptionsVerifyNone captures enum value "none"
	BackendServerCheckSslOptionsVerifyNone string = "none"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type BackendServer

type BackendServer struct {

	// check ssl options
	CheckSslOptions *BackendServerCheckSslOptions `json:"check_ssl_options,omitempty"`

	// Backend server IP address
	// Required: true
	// Pattern: ((^\s*((([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5]))\s*$)|(^\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(%.+)?\s*$))
	Ipaddress string `json:"ipaddress"`

	// Backend server name
	// Required: true
	// Pattern: ^[A-Za-z0-9\-_.]{1,32}$
	Name string `json:"name"`

	// Backend server options
	Options *string `json:"options,omitempty"`

	// Backend server port
	// Required: true
	Port uint16 `json:"port"`
}

BackendServer Backend server

swagger:model BackendServer

func (*BackendServer) ContextValidate

func (m *BackendServer) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validate this backend server based on the context it is used

func (*BackendServer) MarshalBinary

func (m *BackendServer) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*BackendServer) UnmarshalBinary

func (m *BackendServer) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*BackendServer) Validate

func (m *BackendServer) Validate(formats strfmt.Registry) error

Validate validates this backend server

type BackendServerCheckSslOptions

type BackendServerCheckSslOptions struct {

	// ca cert
	CaCert *string `json:"ca_cert,omitempty"`

	// client cert
	ClientCert string `json:"client_cert,omitempty"`

	// client key
	ClientKey string `json:"client_key,omitempty"`

	// verify
	// Enum: [none]
	Verify *string `json:"verify,omitempty"`
}

BackendServerCheckSslOptions Backend check commands

swagger:model BackendServerCheckSslOptions

func (*BackendServerCheckSslOptions) ContextValidate

func (m *BackendServerCheckSslOptions) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this backend server check ssl options based on context it is used

func (*BackendServerCheckSslOptions) MarshalBinary

func (m *BackendServerCheckSslOptions) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*BackendServerCheckSslOptions) UnmarshalBinary

func (m *BackendServerCheckSslOptions) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*BackendServerCheckSslOptions) Validate

func (m *BackendServerCheckSslOptions) Validate(formats strfmt.Registry) error

Validate validates this backend server check ssl options

type Endpoint

type Endpoint struct {

	// backend check commands
	BackendCheckCommands *EndpointBackendCheckCommands `json:"backend_check_commands,omitempty"`

	// Backend default server options
	BackendDefaultServer *string `json:"backend_default_server,omitempty"`

	// Backend options
	// Example: ["httpchk GET /"]
	BackendOptions []string `json:"backend_options"`

	// Backend servers
	// Required: true
	BackendServers []*BackendServer `json:"backend_servers"`

	// Balance algorithm
	// Required: true
	Balance string `json:"balance"`

	// Frontend options
	// Example: ssl
	FrontendOptions *string `json:"frontend_options,omitempty"`

	// Frontend port
	// Example: 443
	// Required: true
	FrontendPort uint16 `json:"frontend_port"`

	// frontend ssl options
	FrontendSslOptions *EndpointFrontendSslOptions `json:"frontend_ssl_options,omitempty"`

	// Protocol mode
	// Required: true
	// Enum: [tcp udp http]
	Mode string `json:"mode"`
}

Endpoint Endpoint

swagger:model Endpoint

func (*Endpoint) ContextValidate

func (m *Endpoint) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validate this endpoint based on the context it is used

func (*Endpoint) MarshalBinary

func (m *Endpoint) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*Endpoint) UnmarshalBinary

func (m *Endpoint) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*Endpoint) Validate

func (m *Endpoint) Validate(formats strfmt.Registry) error

Validate validates this endpoint

type EndpointBackendCheckCommands

type EndpointBackendCheckCommands struct {

	// check type
	// Example: http-check
	// Enum: [http-check tcp-check]
	CheckType string `json:"check_type,omitempty"`

	// Backend TCP check commands
	// Example: ["expect status 200"]
	Commands []string `json:"commands"`
}

EndpointBackendCheckCommands Backend check commands

swagger:model EndpointBackendCheckCommands

func (*EndpointBackendCheckCommands) ContextValidate

func (m *EndpointBackendCheckCommands) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this endpoint backend check commands based on context it is used

func (*EndpointBackendCheckCommands) MarshalBinary

func (m *EndpointBackendCheckCommands) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*EndpointBackendCheckCommands) UnmarshalBinary

func (m *EndpointBackendCheckCommands) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*EndpointBackendCheckCommands) Validate

func (m *EndpointBackendCheckCommands) Validate(formats strfmt.Registry) error

Validate validates this endpoint backend check commands

type EndpointFrontendSslOptions

type EndpointFrontendSslOptions struct {

	// ca cert
	CaCert *string `json:"ca_cert,omitempty"`

	// server cert
	ServerCert string `json:"server_cert,omitempty"`

	// server key
	ServerKey string `json:"server_key,omitempty"`

	// verify
	// Enum: [required optional]
	Verify *string `json:"verify,omitempty"`
}

EndpointFrontendSslOptions Backend check commands

swagger:model EndpointFrontendSslOptions

func (*EndpointFrontendSslOptions) ContextValidate

func (m *EndpointFrontendSslOptions) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this endpoint frontend ssl options based on context it is used

func (*EndpointFrontendSslOptions) MarshalBinary

func (m *EndpointFrontendSslOptions) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*EndpointFrontendSslOptions) UnmarshalBinary

func (m *EndpointFrontendSslOptions) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*EndpointFrontendSslOptions) Validate

func (m *EndpointFrontendSslOptions) Validate(formats strfmt.Registry) error

Validate validates this endpoint frontend ssl options

type Instance

type Instance struct {

	// config
	// Required: true
	Config *InstanceConfig `json:"config"`

	// Instance ID
	// Required: true
	// Maximum: 255
	// Minimum: 0
	ID uint8 `json:"id"`

	// Last modified time
	// Minimum: 0
	LastModified int64 `json:"last_modified,omitempty"`

	// Instance status
	// Required: true
	Status map[string]string `json:"status"`
}

Instance Instance

swagger:model Instance

func (*Instance) ContextValidate

func (m *Instance) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validate this instance based on the context it is used

func (*Instance) MarshalBinary

func (m *Instance) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*Instance) UnmarshalBinary

func (m *Instance) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*Instance) Validate

func (m *Instance) Validate(formats strfmt.Registry) error

Validate validates this instance

type InstanceConfig

type InstanceConfig struct {

	// Endpoints
	// Required: true
	Endpoints []*Endpoint `json:"endpoints"`

	// Frontend network interface
	// Example: eth0
	// Required: true
	// Pattern: ^[A-Za-z0-9\-_.]{1,32}$
	FrontendInterface string `json:"frontend_interface"`

	// Frontend IP address
	// Example: 192.168.1.2
	// Required: true
	// Pattern: ((^\s*((([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5]))\s*$)|(^\s*((([0-9A-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address"`

	// Frontend network prefix
	// Example: 24
	// Required: true
	// Maximum: 32
	// Minimum: 8
	FrontendNetPrefix uint8 `json:"frontend_net_prefix"`

	// Instance name
	// Required: true
	// Pattern: ^[A-Za-z0-9\-_.]{1,32}$
	Name string `json:"name"`
}

InstanceConfig Instance config

swagger:model InstanceConfig

func (*InstanceConfig) ContextValidate

func (m *InstanceConfig) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validate this instance config based on the context it is used

func (*InstanceConfig) MarshalBinary

func (m *InstanceConfig) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*InstanceConfig) UnmarshalBinary

func (m *InstanceConfig) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*InstanceConfig) Validate

func (m *InstanceConfig) Validate(formats strfmt.Registry) error

Validate validates this instance config

type ReadyStatus

type ReadyStatus map[string]string

ReadyStatus Ready status

swagger:model ReadyStatus

func (ReadyStatus) ContextValidate

func (m ReadyStatus) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this ready status based on context it is used

func (ReadyStatus) Validate

func (m ReadyStatus) Validate(formats strfmt.Registry) error

Validate validates this ready status

Jump to

Keyboard shortcuts

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