Documentation
¶
Index ¶
- Constants
- type ACL
- type ACLAction
- type ACLActionType
- type ACLHTTPFilter
- type ACLMatch
- type API
- func (s *API) AddBackendServers(req *AddBackendServersRequest, opts ...scw.RequestOption) (*Backend, error)
- func (s *API) CreateACL(req *CreateACLRequest, opts ...scw.RequestOption) (*ACL, error)
- func (s *API) CreateBackend(req *CreateBackendRequest, opts ...scw.RequestOption) (*Backend, error)
- func (s *API) CreateCertificate(req *CreateCertificateRequest, opts ...scw.RequestOption) (*Certificate, error)
- func (s *API) CreateFrontend(req *CreateFrontendRequest, opts ...scw.RequestOption) (*Frontend, error)
- func (s *API) CreateLb(req *CreateLbRequest, opts ...scw.RequestOption) (*Lb, error)
- func (s *API) DeleteACL(req *DeleteACLRequest, opts ...scw.RequestOption) error
- func (s *API) DeleteBackend(req *DeleteBackendRequest, opts ...scw.RequestOption) error
- func (s *API) DeleteCertificate(req *DeleteCertificateRequest, opts ...scw.RequestOption) error
- func (s *API) DeleteFrontend(req *DeleteFrontendRequest, opts ...scw.RequestOption) error
- func (s *API) DeleteLb(req *DeleteLbRequest, opts ...scw.RequestOption) error
- func (s *API) GetACL(req *GetACLRequest, opts ...scw.RequestOption) (*ACL, error)
- func (s *API) GetBackend(req *GetBackendRequest, opts ...scw.RequestOption) (*Backend, error)
- func (s *API) GetCertificate(req *GetCertificateRequest, opts ...scw.RequestOption) (*Certificate, error)
- func (s *API) GetFrontend(req *GetFrontendRequest, opts ...scw.RequestOption) (*Frontend, error)
- func (s *API) GetIP(req *GetIPRequest, opts ...scw.RequestOption) (*IP, error)
- func (s *API) GetLb(req *GetLbRequest, opts ...scw.RequestOption) (*Lb, error)
- func (s *API) GetLbStats(req *GetLbStatsRequest, opts ...scw.RequestOption) (*LbStats, error)
- func (s *API) GetServiceInfo(req *GetServiceInfoRequest, opts ...scw.RequestOption) (*scw.ServiceInfo, error)
- func (s *API) ListACLs(req *ListACLsRequest, opts ...scw.RequestOption) (*ListACLResponse, error)
- func (s *API) ListBackends(req *ListBackendsRequest, opts ...scw.RequestOption) (*ListBackendsResponse, error)
- func (s *API) ListCertificates(req *ListCertificatesRequest, opts ...scw.RequestOption) (*ListCertificatesResponse, error)
- func (s *API) ListFrontends(req *ListFrontendsRequest, opts ...scw.RequestOption) (*ListFrontendsResponse, error)
- func (s *API) ListIPs(req *ListIPsRequest, opts ...scw.RequestOption) (*ListIPsResponse, error)
- func (s *API) ListLbTypes(req *ListLbTypesRequest, opts ...scw.RequestOption) (*ListLbTypesResponse, error)
- func (s *API) ListLbs(req *ListLbsRequest, opts ...scw.RequestOption) (*ListLbsResponse, error)
- func (s *API) ReleaseIP(req *ReleaseIPRequest, opts ...scw.RequestOption) error
- func (s *API) RemoveBackendServers(req *RemoveBackendServersRequest, opts ...scw.RequestOption) (*Backend, error)
- func (s *API) SetBackendServers(req *SetBackendServersRequest, opts ...scw.RequestOption) (*Backend, error)
- func (s *API) UpdateACL(req *UpdateACLRequest, opts ...scw.RequestOption) (*ACL, error)
- func (s *API) UpdateBackend(req *UpdateBackendRequest, opts ...scw.RequestOption) (*Backend, error)
- func (s *API) UpdateCertificate(req *UpdateCertificateRequest, opts ...scw.RequestOption) (*Certificate, error)
- func (s *API) UpdateFrontend(req *UpdateFrontendRequest, opts ...scw.RequestOption) (*Frontend, error)
- func (s *API) UpdateHealthCheck(req *UpdateHealthCheckRequest, opts ...scw.RequestOption) (*HealthCheck, error)
- func (s *API) UpdateIP(req *UpdateIPRequest, opts ...scw.RequestOption) (*IP, error)
- func (s *API) UpdateLb(req *UpdateLbRequest, opts ...scw.RequestOption) (*Lb, error)
- type AddBackendServersRequest
- type Backend
- type BackendServerStats
- type BackendServerStatsHealthCheckStatus
- type BackendServerStatsServerState
- type Certificate
- type CertificateStatus
- type CertificateType
- type Config
- type ConfigHTTPConfig
- type ConfigHTTPSConfig
- type ConfigLdapConfig
- type ConfigMysqlConfig
- type ConfigPgsqlConfig
- type ConfigRedisConfig
- type ConfigTCPConfig
- type CreateACLRequest
- type CreateBackendRequest
- type CreateCertificateRequest
- type CreateCertificateRequestLetsencryptConfig
- type CreateFrontendRequest
- type CreateLbRequest
- type DeleteACLRequest
- type DeleteBackendRequest
- type DeleteCertificateRequest
- type DeleteFrontendRequest
- type DeleteLbRequest
- type ForwardPortAlgorithm
- type Frontend
- type GetACLRequest
- type GetBackendRequest
- type GetCertificateRequest
- type GetFrontendRequest
- type GetIPRequest
- type GetLbRequest
- type GetLbStatsRequest
- type GetServiceInfoRequest
- type HealthCheck
- type HealthCheckHTTPConfig
- type HealthCheckHTTPSConfig
- type HealthCheckLdapConfig
- type HealthCheckMysqlConfig
- type HealthCheckPgsqlConfig
- type HealthCheckRedisConfig
- type HealthCheckTCPConfig
- type IP
- type Instance
- type InstanceStatus
- type Lb
- type LbStats
- type LbStatus
- type LbType
- type LbTypeStock
- type ListACLRequestOrderBy
- type ListACLResponse
- type ListACLsRequest
- type ListBackendsRequest
- type ListBackendsRequestOrderBy
- type ListBackendsResponse
- type ListCertificatesRequest
- type ListCertificatesRequestOrderBy
- type ListCertificatesResponse
- type ListFrontendsRequest
- type ListFrontendsRequestOrderBy
- type ListFrontendsResponse
- type ListIPsRequest
- type ListIPsResponse
- type ListLbTypesRequest
- type ListLbTypesResponse
- type ListLbsRequest
- type ListLbsRequestOrderBy
- type ListLbsResponse
- type OnMarkedDownAction
- type Protocol
- type ReleaseIPRequest
- type RemoveBackendServersRequest
- type SetBackendServersRequest
- type StickySessionsType
- type Type
- type TypeLetsencrypt
- type UpdateACLRequest
- type UpdateBackendRequest
- type UpdateCertificateRequest
- type UpdateFrontendRequest
- type UpdateHealthCheckRequest
- type UpdateIPRequest
- type UpdateLbRequest
Constants ¶
const ( // ACLActionTypeAllow is [insert doc]. ACLActionTypeAllow = ACLActionType("allow") // ACLActionTypeDeny is [insert doc]. ACLActionTypeDeny = ACLActionType("deny") )
const ( // ACLHTTPFilterACLHTTPFilterNone is [insert doc]. ACLHTTPFilterACLHTTPFilterNone = ACLHTTPFilter("acl_http_filter_none") // ACLHTTPFilterPathBegin is [insert doc]. ACLHTTPFilterPathBegin = ACLHTTPFilter("path_begin") // ACLHTTPFilterPathEnd is [insert doc]. ACLHTTPFilterPathEnd = ACLHTTPFilter("path_end") // ACLHTTPFilterRegex is [insert doc]. ACLHTTPFilterRegex = ACLHTTPFilter("regex") )
const ( // BackendServerStatsHealthCheckStatusUnknown is [insert doc]. BackendServerStatsHealthCheckStatusUnknown = BackendServerStatsHealthCheckStatus("unknown") // BackendServerStatsHealthCheckStatusNeutral is [insert doc]. BackendServerStatsHealthCheckStatusNeutral = BackendServerStatsHealthCheckStatus("neutral") // BackendServerStatsHealthCheckStatusFailed is [insert doc]. BackendServerStatsHealthCheckStatusFailed = BackendServerStatsHealthCheckStatus("failed") // BackendServerStatsHealthCheckStatusPassed is [insert doc]. BackendServerStatsHealthCheckStatusPassed = BackendServerStatsHealthCheckStatus("passed") // BackendServerStatsHealthCheckStatusCondpass is [insert doc]. BackendServerStatsHealthCheckStatusCondpass = BackendServerStatsHealthCheckStatus("condpass") )
const ( // BackendServerStatsServerStateStopped is [insert doc]. BackendServerStatsServerStateStopped = BackendServerStatsServerState("stopped") // BackendServerStatsServerStateStarting is [insert doc]. BackendServerStatsServerStateStarting = BackendServerStatsServerState("starting") // BackendServerStatsServerStateRunning is [insert doc]. BackendServerStatsServerStateRunning = BackendServerStatsServerState("running") // BackendServerStatsServerStateStopping is [insert doc]. BackendServerStatsServerStateStopping = BackendServerStatsServerState("stopping") )
const ( // CertificateStatusPending is [insert doc]. CertificateStatusPending = CertificateStatus("pending") // CertificateStatusReady is [insert doc]. CertificateStatusReady = CertificateStatus("ready") // CertificateStatusError is [insert doc]. CertificateStatusError = CertificateStatus("error") )
const ( // ForwardPortAlgorithmRoundrobin is [insert doc]. ForwardPortAlgorithmRoundrobin = ForwardPortAlgorithm("roundrobin") // ForwardPortAlgorithmLeastconn is [insert doc]. ForwardPortAlgorithmLeastconn = ForwardPortAlgorithm("leastconn") )
const ( // InstanceStatusUnknown is [insert doc]. InstanceStatusUnknown = InstanceStatus("unknown") // InstanceStatusReady is [insert doc]. InstanceStatusReady = InstanceStatus("ready") // InstanceStatusPending is [insert doc]. InstanceStatusPending = InstanceStatus("pending") // InstanceStatusStopped is [insert doc]. InstanceStatusStopped = InstanceStatus("stopped") // InstanceStatusError is [insert doc]. InstanceStatusError = InstanceStatus("error") // InstanceStatusLocked is [insert doc]. InstanceStatusLocked = InstanceStatus("locked") )
const ( // LbStatusUnknown is [insert doc]. LbStatusUnknown = LbStatus("unknown") // LbStatusReady is [insert doc]. LbStatusReady = LbStatus("ready") // LbStatusPending is [insert doc]. LbStatusPending = LbStatus("pending") // LbStatusStopped is [insert doc]. LbStatusStopped = LbStatus("stopped") // LbStatusError is [insert doc]. LbStatusError = LbStatus("error") // LbStatusLocked is [insert doc]. LbStatusLocked = LbStatus("locked") )
const ( // LbTypeStockUnknown is [insert doc]. LbTypeStockUnknown = LbTypeStock("unknown") // LbTypeStockLowStock is [insert doc]. LbTypeStockLowStock = LbTypeStock("low_stock") // LbTypeStockOutOfStock is [insert doc]. LbTypeStockOutOfStock = LbTypeStock("out_of_stock") // LbTypeStockAvailable is [insert doc]. LbTypeStockAvailable = LbTypeStock("available") )
const ( // ListACLRequestOrderByCreatedAtAsc is [insert doc]. ListACLRequestOrderByCreatedAtAsc = ListACLRequestOrderBy("created_at_asc") // ListACLRequestOrderByCreatedAtDesc is [insert doc]. ListACLRequestOrderByCreatedAtDesc = ListACLRequestOrderBy("created_at_desc") // ListACLRequestOrderByNameAsc is [insert doc]. ListACLRequestOrderByNameAsc = ListACLRequestOrderBy("name_asc") // ListACLRequestOrderByNameDesc is [insert doc]. ListACLRequestOrderByNameDesc = ListACLRequestOrderBy("name_desc") )
const ( // ListBackendsRequestOrderByCreatedAtAsc is [insert doc]. ListBackendsRequestOrderByCreatedAtAsc = ListBackendsRequestOrderBy("created_at_asc") // ListBackendsRequestOrderByCreatedAtDesc is [insert doc]. ListBackendsRequestOrderByCreatedAtDesc = ListBackendsRequestOrderBy("created_at_desc") // ListBackendsRequestOrderByNameAsc is [insert doc]. ListBackendsRequestOrderByNameAsc = ListBackendsRequestOrderBy("name_asc") // ListBackendsRequestOrderByNameDesc is [insert doc]. ListBackendsRequestOrderByNameDesc = ListBackendsRequestOrderBy("name_desc") )
const ( // ListCertificatesRequestOrderByCreatedAtAsc is [insert doc]. ListCertificatesRequestOrderByCreatedAtAsc = ListCertificatesRequestOrderBy("created_at_asc") // ListCertificatesRequestOrderByCreatedAtDesc is [insert doc]. ListCertificatesRequestOrderByCreatedAtDesc = ListCertificatesRequestOrderBy("created_at_desc") // ListCertificatesRequestOrderByNameAsc is [insert doc]. ListCertificatesRequestOrderByNameAsc = ListCertificatesRequestOrderBy("name_asc") // ListCertificatesRequestOrderByNameDesc is [insert doc]. ListCertificatesRequestOrderByNameDesc = ListCertificatesRequestOrderBy("name_desc") )
const ( // ListFrontendsRequestOrderByCreatedAtAsc is [insert doc]. ListFrontendsRequestOrderByCreatedAtAsc = ListFrontendsRequestOrderBy("created_at_asc") // ListFrontendsRequestOrderByCreatedAtDesc is [insert doc]. ListFrontendsRequestOrderByCreatedAtDesc = ListFrontendsRequestOrderBy("created_at_desc") // ListFrontendsRequestOrderByNameAsc is [insert doc]. ListFrontendsRequestOrderByNameAsc = ListFrontendsRequestOrderBy("name_asc") // ListFrontendsRequestOrderByNameDesc is [insert doc]. ListFrontendsRequestOrderByNameDesc = ListFrontendsRequestOrderBy("name_desc") )
const ( // ListLbsRequestOrderByCreatedAtAsc is [insert doc]. ListLbsRequestOrderByCreatedAtAsc = ListLbsRequestOrderBy("created_at_asc") // ListLbsRequestOrderByCreatedAtDesc is [insert doc]. ListLbsRequestOrderByCreatedAtDesc = ListLbsRequestOrderBy("created_at_desc") // ListLbsRequestOrderByNameAsc is [insert doc]. ListLbsRequestOrderByNameAsc = ListLbsRequestOrderBy("name_asc") // ListLbsRequestOrderByNameDesc is [insert doc]. ListLbsRequestOrderByNameDesc = ListLbsRequestOrderBy("name_desc") )
const ( // OnMarkedDownActionOnMarkedDownActionNone is [insert doc]. OnMarkedDownActionOnMarkedDownActionNone = OnMarkedDownAction("on_marked_down_action_none") // OnMarkedDownActionShutdownSessions is [insert doc]. OnMarkedDownActionShutdownSessions = OnMarkedDownAction("shutdown_sessions") )
const ( // ProtocolTCP is [insert doc]. ProtocolTCP = Protocol("tcp") // ProtocolHTTP is [insert doc]. ProtocolHTTP = Protocol("http") )
const ( // StickySessionsTypeNone is [insert doc]. StickySessionsTypeNone = StickySessionsType("none") // StickySessionsTypeCookie is [insert doc]. StickySessionsTypeCookie = StickySessionsType("cookie") // StickySessionsTypeTable is [insert doc]. StickySessionsTypeTable = StickySessionsType("table") )
const ( // CertificateTypeLetsencryt is [insert doc]. CertificateTypeLetsencryt = CertificateType("letsencryt") )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ACL ¶
type ACL struct {
// ID iD of your ACL ressource
ID string `json:"id"`
// Name name of you ACL ressource
Name string `json:"name"`
// Match see the AclMatch object description
Match *ACLMatch `json:"match"`
// Action see the AclAction object description
Action *ACLAction `json:"action"`
// Frontend see the Frontend object description
Frontend *Frontend `json:"frontend"`
// Index order between your Acls (ascending order, 0 is first acl executed)
Index int32 `json:"index"`
}
ACL the use of Access Control Lists (ACL) provide a flexible solution to perform a action generally consist in blocking or allow a request based on ip (and URL on HTTP)
type ACLAction ¶
type ACLAction struct {
// Type <allow> or <deny> request
//
// Default value: allow
Type ACLActionType `json:"type"`
}
ACLAction action if your ACL filter match
type ACLActionType ¶
type ACLActionType string
func (ACLActionType) MarshalJSON ¶
func (enum ACLActionType) MarshalJSON() ([]byte, error)
func (ACLActionType) String ¶
func (enum ACLActionType) String() string
func (*ACLActionType) UnmarshalJSON ¶
func (enum *ACLActionType) UnmarshalJSON(data []byte) error
type ACLHTTPFilter ¶
type ACLHTTPFilter string
func (ACLHTTPFilter) MarshalJSON ¶
func (enum ACLHTTPFilter) MarshalJSON() ([]byte, error)
func (ACLHTTPFilter) String ¶
func (enum ACLHTTPFilter) String() string
func (*ACLHTTPFilter) UnmarshalJSON ¶
func (enum *ACLHTTPFilter) UnmarshalJSON(data []byte) error
type ACLMatch ¶
type ACLMatch struct {
// IPSubnet this is the source IP v4/v6 address of the client of the session to match or not. Addresses values can be specified either as plain addresses or with a netmask appended
IPSubnet []*string `json:"ip_subnet"`
// HTTPFilter you can set http filter (if your backend protocole have a http forward protocol. This extracts the request's URL path, which starts at the first slash and ends before the question mark (without the host part). You can choose between <path_begin> prefix match (like /admin), <path_end> suffix match (like .php) and <regex>
//
// Default value: acl_http_filter_none
HTTPFilter ACLHTTPFilter `json:"http_filter"`
HTTPFilterValue []*string `json:"http_filter_value"`
// Invert by default match filter is a IF condition. You can set invert to true to have a unless condition
Invert bool `json:"invert"`
}
ACLMatch settings of your ACL filter
type API ¶
type API struct {
// contains filtered or unexported fields
}
API this API allows you to manage your Load Balancer service
func (*API) AddBackendServers ¶
func (s *API) AddBackendServers(req *AddBackendServersRequest, opts ...scw.RequestOption) (*Backend, error)
func (*API) CreateACL ¶
func (s *API) CreateACL(req *CreateACLRequest, opts ...scw.RequestOption) (*ACL, error)
func (*API) CreateBackend ¶
func (s *API) CreateBackend(req *CreateBackendRequest, opts ...scw.RequestOption) (*Backend, error)
func (*API) CreateCertificate ¶
func (s *API) CreateCertificate(req *CreateCertificateRequest, opts ...scw.RequestOption) (*Certificate, error)
CreateCertificate create Certificate
Generate a new SSL certificate using Let's Encrypt (Custom certificates can be imported soon)
func (*API) CreateFrontend ¶
func (s *API) CreateFrontend(req *CreateFrontendRequest, opts ...scw.RequestOption) (*Frontend, error)
func (*API) CreateLb ¶
func (s *API) CreateLb(req *CreateLbRequest, opts ...scw.RequestOption) (*Lb, error)
func (*API) DeleteACL ¶
func (s *API) DeleteACL(req *DeleteACLRequest, opts ...scw.RequestOption) error
func (*API) DeleteBackend ¶
func (s *API) DeleteBackend(req *DeleteBackendRequest, opts ...scw.RequestOption) error
func (*API) DeleteCertificate ¶
func (s *API) DeleteCertificate(req *DeleteCertificateRequest, opts ...scw.RequestOption) error
DeleteCertificate delete Certificate
func (*API) DeleteFrontend ¶
func (s *API) DeleteFrontend(req *DeleteFrontendRequest, opts ...scw.RequestOption) error
func (*API) DeleteLb ¶
func (s *API) DeleteLb(req *DeleteLbRequest, opts ...scw.RequestOption) error
func (*API) GetACL ¶
func (s *API) GetACL(req *GetACLRequest, opts ...scw.RequestOption) (*ACL, error)
func (*API) GetBackend ¶
func (s *API) GetBackend(req *GetBackendRequest, opts ...scw.RequestOption) (*Backend, error)
func (*API) GetCertificate ¶
func (s *API) GetCertificate(req *GetCertificateRequest, opts ...scw.RequestOption) (*Certificate, error)
GetCertificate get Certificate
func (*API) GetFrontend ¶
func (s *API) GetFrontend(req *GetFrontendRequest, opts ...scw.RequestOption) (*Frontend, error)
func (*API) GetIP ¶
func (s *API) GetIP(req *GetIPRequest, opts ...scw.RequestOption) (*IP, error)
GetIP get IP
func (*API) GetLb ¶
func (s *API) GetLb(req *GetLbRequest, opts ...scw.RequestOption) (*Lb, error)
func (*API) GetLbStats ¶
func (s *API) GetLbStats(req *GetLbStatsRequest, opts ...scw.RequestOption) (*LbStats, error)
func (*API) GetServiceInfo ¶
func (s *API) GetServiceInfo(req *GetServiceInfoRequest, opts ...scw.RequestOption) (*scw.ServiceInfo, error)
func (*API) ListACLs ¶
func (s *API) ListACLs(req *ListACLsRequest, opts ...scw.RequestOption) (*ListACLResponse, error)
func (*API) ListBackends ¶
func (s *API) ListBackends(req *ListBackendsRequest, opts ...scw.RequestOption) (*ListBackendsResponse, error)
func (*API) ListCertificates ¶
func (s *API) ListCertificates(req *ListCertificatesRequest, opts ...scw.RequestOption) (*ListCertificatesResponse, error)
ListCertificates list Certificates
func (*API) ListFrontends ¶
func (s *API) ListFrontends(req *ListFrontendsRequest, opts ...scw.RequestOption) (*ListFrontendsResponse, error)
func (*API) ListIPs ¶
func (s *API) ListIPs(req *ListIPsRequest, opts ...scw.RequestOption) (*ListIPsResponse, error)
ListIPs list IPs
func (*API) ListLbTypes ¶
func (s *API) ListLbTypes(req *ListLbTypesRequest, opts ...scw.RequestOption) (*ListLbTypesResponse, error)
ListLbTypes list all Load Balancer offer type
func (*API) ListLbs ¶
func (s *API) ListLbs(req *ListLbsRequest, opts ...scw.RequestOption) (*ListLbsResponse, error)
func (*API) ReleaseIP ¶
func (s *API) ReleaseIP(req *ReleaseIPRequest, opts ...scw.RequestOption) error
ReleaseIP release IP
func (*API) RemoveBackendServers ¶
func (s *API) RemoveBackendServers(req *RemoveBackendServersRequest, opts ...scw.RequestOption) (*Backend, error)
func (*API) SetBackendServers ¶
func (s *API) SetBackendServers(req *SetBackendServersRequest, opts ...scw.RequestOption) (*Backend, error)
func (*API) UpdateACL ¶
func (s *API) UpdateACL(req *UpdateACLRequest, opts ...scw.RequestOption) (*ACL, error)
func (*API) UpdateBackend ¶
func (s *API) UpdateBackend(req *UpdateBackendRequest, opts ...scw.RequestOption) (*Backend, error)
func (*API) UpdateCertificate ¶
func (s *API) UpdateCertificate(req *UpdateCertificateRequest, opts ...scw.RequestOption) (*Certificate, error)
UpdateCertificate update Certificate
func (*API) UpdateFrontend ¶
func (s *API) UpdateFrontend(req *UpdateFrontendRequest, opts ...scw.RequestOption) (*Frontend, error)
func (*API) UpdateHealthCheck ¶
func (s *API) UpdateHealthCheck(req *UpdateHealthCheckRequest, opts ...scw.RequestOption) (*HealthCheck, error)
func (*API) UpdateIP ¶
func (s *API) UpdateIP(req *UpdateIPRequest, opts ...scw.RequestOption) (*IP, error)
func (*API) UpdateLb ¶
func (s *API) UpdateLb(req *UpdateLbRequest, opts ...scw.RequestOption) (*Lb, error)
type Backend ¶
type Backend struct {
ID string `json:"id"`
Name string `json:"name"`
// ForwardProtocol
//
// Default value: tcp
ForwardProtocol Protocol `json:"forward_protocol"`
ForwardPort int32 `json:"forward_port"`
// ForwardPortAlgorithm
//
// Default value: roundrobin
ForwardPortAlgorithm ForwardPortAlgorithm `json:"forward_port_algorithm"`
// StickySessions
//
// Default value: none
StickySessions StickySessionsType `json:"sticky_sessions"`
StickySessionsCookieName string `json:"sticky_sessions_cookie_name"`
HealthCheck *HealthCheck `json:"health_check"`
Pool []string `json:"pool"`
Lb *Lb `json:"lb"`
SendProxyV2 bool `json:"send_proxy_v2"`
TimeoutServer *time.Duration `json:"timeout_server"`
TimeoutConnect *time.Duration `json:"timeout_connect"`
TimeoutTunnel *time.Duration `json:"timeout_tunnel"`
// OnMarkedDownAction
//
// Default value: on_marked_down_action_none
OnMarkedDownAction OnMarkedDownAction `json:"on_marked_down_action"`
}
func (Backend) MarshalJSON ¶
func (*Backend) UnmarshalJSON ¶
type BackendServerStats ¶
type BackendServerStats struct {
// InstanceID iD of your loadbalancer cluster server
InstanceID string `json:"instance_id"`
// BackendID iD of your Backend
BackendID string `json:"backend_id"`
// IP iPv4 or IPv6 address of the server backend
IP string `json:"ip"`
// ServerState server operational state (stopped/starting/running/stopping)
//
// Default value: stopped
ServerState BackendServerStatsServerState `json:"server_state"`
// ServerStateChangedAt time since last operational change
ServerStateChangedAt time.Time `json:"server_state_changed_at"`
// LastHealthCheckStatus last health check status (unknown/neutral/failed/passed/condpass)
//
// Default value: unknown
LastHealthCheckStatus BackendServerStatsHealthCheckStatus `json:"last_health_check_status"`
}
BackendServerStats state and statistics of your backend server like last healthcheck status, server uptime, result state of your backend server
type BackendServerStatsHealthCheckStatus ¶
type BackendServerStatsHealthCheckStatus string
func (BackendServerStatsHealthCheckStatus) MarshalJSON ¶
func (enum BackendServerStatsHealthCheckStatus) MarshalJSON() ([]byte, error)
func (BackendServerStatsHealthCheckStatus) String ¶
func (enum BackendServerStatsHealthCheckStatus) String() string
func (*BackendServerStatsHealthCheckStatus) UnmarshalJSON ¶
func (enum *BackendServerStatsHealthCheckStatus) UnmarshalJSON(data []byte) error
type BackendServerStatsServerState ¶
type BackendServerStatsServerState string
func (BackendServerStatsServerState) MarshalJSON ¶
func (enum BackendServerStatsServerState) MarshalJSON() ([]byte, error)
func (BackendServerStatsServerState) String ¶
func (enum BackendServerStatsServerState) String() string
func (*BackendServerStatsServerState) UnmarshalJSON ¶
func (enum *BackendServerStatsServerState) UnmarshalJSON(data []byte) error
type Certificate ¶
type Certificate struct {
// Type type of certificate (custom coming soon)
//
// Default value: letsencryt
Type CertificateType `json:"type"`
// ID certificate ID
ID string `json:"id"`
// CommonName main domain name of certificate
CommonName string `json:"common_name"`
// SubjectAlternativeName alternative domain names
SubjectAlternativeName []string `json:"subject_alternative_name"`
// Fingerprint identifier (SHA-1) of the certificate
Fingerprint string `json:"fingerprint"`
// NotValidBefore validity bounds
NotValidBefore time.Time `json:"not_valid_before"`
// NotValidAfter validity bounds
NotValidAfter time.Time `json:"not_valid_after"`
// Status status of certificate
//
// Default value: pending
Status CertificateStatus `json:"status"`
// Lb load Balancer object
Lb *Lb `json:"lb"`
// Name certificate name
Name string `json:"name"`
}
Certificate sSL certificate
type CertificateStatus ¶
type CertificateStatus string
func (CertificateStatus) MarshalJSON ¶
func (enum CertificateStatus) MarshalJSON() ([]byte, error)
func (CertificateStatus) String ¶
func (enum CertificateStatus) String() string
func (*CertificateStatus) UnmarshalJSON ¶
func (enum *CertificateStatus) UnmarshalJSON(data []byte) error
type CertificateType ¶
type CertificateType string
func (CertificateType) MarshalJSON ¶
func (enum CertificateType) MarshalJSON() ([]byte, error)
func (CertificateType) String ¶
func (enum CertificateType) String() string
func (*CertificateType) UnmarshalJSON ¶
func (enum *CertificateType) UnmarshalJSON(data []byte) error
type ConfigHTTPConfig ¶
type ConfigHTTPConfig struct {
Value HealthCheckHTTPConfig
}
type ConfigHTTPSConfig ¶
type ConfigHTTPSConfig struct {
Value HealthCheckHTTPSConfig
}
type ConfigLdapConfig ¶
type ConfigLdapConfig struct {
Value HealthCheckLdapConfig
}
type ConfigMysqlConfig ¶
type ConfigMysqlConfig struct {
Value HealthCheckMysqlConfig
}
type ConfigPgsqlConfig ¶
type ConfigPgsqlConfig struct {
Value HealthCheckPgsqlConfig
}
type ConfigRedisConfig ¶
type ConfigRedisConfig struct {
Value HealthCheckRedisConfig
}
type ConfigTCPConfig ¶
type ConfigTCPConfig struct {
Value HealthCheckTCPConfig
}
type CreateACLRequest ¶
type CreateACLRequest struct {
Region scw.Region `json:"-"`
// FrontendID iD of your frontend
FrontendID string `json:"-"`
// Name name of your ACL ressource
Name string `json:"name"`
// Action see the AclAction object description
Action *ACLAction `json:"action"`
// Match see the AclMatch object description
Match *ACLMatch `json:"match"`
// Index order between your Acls (ascending order, 0 is first acl executed)
Index int32 `json:"index"`
}
type CreateBackendRequest ¶
type CreateBackendRequest struct {
Region scw.Region `json:"-"`
// LbID load Balancer ID
LbID string `json:"-"`
// Name resource name
Name string `json:"name"`
// ForwardProtocol backend protocol. TCP or HTTP
//
// Default value: tcp
ForwardProtocol Protocol `json:"forward_protocol"`
// ForwardPort user sessions will be forwarded to this port of backend servers
ForwardPort int32 `json:"forward_port"`
// ForwardPortAlgorithm load balancing algorithm
//
// Default value: roundrobin
ForwardPortAlgorithm ForwardPortAlgorithm `json:"forward_port_algorithm"`
// StickySessions enables cookie-based session persistence
//
// Default value: none
StickySessions StickySessionsType `json:"sticky_sessions"`
// StickySessionsCookieName cookie name for for sticky sessions
StickySessionsCookieName string `json:"sticky_sessions_cookie_name"`
// HealthCheck see the Healthcheck object description
HealthCheck *HealthCheck `json:"health_check"`
// ServerIP backend server IP addresses list (IPv4 or IPv6)
ServerIP []string `json:"server_ip"`
// SendProxyV2 enables PROXY protocol version 2 (must be supported by backend servers)
SendProxyV2 bool `json:"send_proxy_v2"`
// TimeoutServer maximum server connection inactivity time
TimeoutServer *time.Duration `json:"timeout_server"`
// TimeoutConnect maximum initical server connection establishment time
TimeoutConnect *time.Duration `json:"timeout_connect"`
// TimeoutTunnel maximum tunnel inactivity time
TimeoutTunnel *time.Duration `json:"timeout_tunnel"`
// OnMarkedDownAction modify what occurs when a backend server is marked down
//
// Default value: on_marked_down_action_none
OnMarkedDownAction OnMarkedDownAction `json:"on_marked_down_action"`
}
func (CreateBackendRequest) MarshalJSON ¶
func (m CreateBackendRequest) MarshalJSON() ([]byte, error)
func (*CreateBackendRequest) UnmarshalJSON ¶
func (m *CreateBackendRequest) UnmarshalJSON(b []byte) error
type CreateCertificateRequest ¶
type CreateCertificateRequest struct {
Region scw.Region `json:"-"`
// LbID load Balancer ID
LbID string `json:"-"`
// Name certificate name
Name string `json:"name"`
// Letsencrypt let's Encrypt type
// Precisely one of Letsencrypt must be set.
Letsencrypt *CreateCertificateRequestLetsencryptConfig `json:"letsencrypt,omitempty"`
}
func (*CreateCertificateRequest) GetType ¶
func (m *CreateCertificateRequest) GetType() Type
type CreateCertificateRequestLetsencryptConfig ¶
type CreateCertificateRequestLetsencryptConfig struct {
// CommonName main domain name of certificate (make sure this domain exists and resolves to your Load Balancer HA IP)
CommonName string `json:"common_name"`
// SubjectAlternativeName alternative domain names (make sure all domain names exists and resolves to your Load Balancer HA IP)
SubjectAlternativeName []string `json:"subject_alternative_name"`
}
CreateCertificateRequestLetsencryptConfig generate a new SSL certificate using Let's Encrypt.
type CreateFrontendRequest ¶
type CreateFrontendRequest struct {
Region scw.Region `json:"-"`
// LbID load Balancer ID
LbID string `json:"-"`
// Name resource name
Name string `json:"name"`
// InboundPort tCP port to listen on the front side
InboundPort int32 `json:"inbound_port"`
// BackendID backend ID
BackendID string `json:"backend_id"`
// TimeoutClient set the maximum inactivity time on the client side
TimeoutClient *time.Duration `json:"timeout_client"`
// CertificateID certificate ID
CertificateID *string `json:"certificate_id"`
}
func (CreateFrontendRequest) MarshalJSON ¶
func (m CreateFrontendRequest) MarshalJSON() ([]byte, error)
func (*CreateFrontendRequest) UnmarshalJSON ¶
func (m *CreateFrontendRequest) UnmarshalJSON(b []byte) error
type CreateLbRequest ¶
type CreateLbRequest struct {
Region scw.Region `json:"-"`
// OrganizationID owner of resources
OrganizationID string `json:"organization_id"`
// Name resource names
Name string `json:"name"`
// Description resource description
Description string `json:"description"`
// IPID just like for compute instances, when you destroy a Load Balancer, you can keep its highly available IP address and reuse it for another Load Balancer later.
IPID *string `json:"ip_id"`
// Tags list of keyword
Tags []string `json:"tags"`
// Type load Balancer offer type
Type string `json:"type"`
}
type DeleteACLRequest ¶
type DeleteBackendRequest ¶
type DeleteFrontendRequest ¶
type DeleteLbRequest ¶
type ForwardPortAlgorithm ¶
type ForwardPortAlgorithm string
func (ForwardPortAlgorithm) MarshalJSON ¶
func (enum ForwardPortAlgorithm) MarshalJSON() ([]byte, error)
func (ForwardPortAlgorithm) String ¶
func (enum ForwardPortAlgorithm) String() string
func (*ForwardPortAlgorithm) UnmarshalJSON ¶
func (enum *ForwardPortAlgorithm) UnmarshalJSON(data []byte) error
type Frontend ¶
type Frontend struct {
ID string `json:"id"`
Name string `json:"name"`
InboundPort int32 `json:"inbound_port"`
Backend *Backend `json:"backend"`
Lb *Lb `json:"lb"`
TimeoutClient *time.Duration `json:"timeout_client"`
Certificate *Certificate `json:"certificate"`
}
func (Frontend) MarshalJSON ¶
func (*Frontend) UnmarshalJSON ¶
type GetACLRequest ¶
type GetBackendRequest ¶
type GetCertificateRequest ¶
type GetFrontendRequest ¶
type GetIPRequest ¶
type GetLbRequest ¶
type GetLbStatsRequest ¶
type GetServiceInfoRequest ¶
type HealthCheck ¶
type HealthCheck struct {
// MysqlConfig the check requires MySQL >=3.22, for older versions, use TCP check
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
MysqlConfig *HealthCheckMysqlConfig `json:"mysql_config,omitempty"`
// LdapConfig the response is analyzed to find an LDAPv3 response message
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
LdapConfig *HealthCheckLdapConfig `json:"ldap_config,omitempty"`
// RedisConfig the response is analyzed to find the +PONG response message
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
RedisConfig *HealthCheckRedisConfig `json:"redis_config,omitempty"`
CheckMaxRetries int32 `json:"check_max_retries"`
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
TCPConfig *HealthCheckTCPConfig `json:"tcp_config,omitempty"`
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
PgsqlConfig *HealthCheckPgsqlConfig `json:"pgsql_config,omitempty"`
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
HTTPConfig *HealthCheckHTTPConfig `json:"http_config,omitempty"`
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
HTTPSConfig *HealthCheckHTTPSConfig `json:"https_config,omitempty"`
Port int32 `json:"port"`
CheckTimeout *time.Duration `json:"check_timeout"`
CheckDelay *time.Duration `json:"check_delay"`
}
func (*HealthCheck) GetConfig ¶
func (m *HealthCheck) GetConfig() Config
func (HealthCheck) MarshalJSON ¶
func (m HealthCheck) MarshalJSON() ([]byte, error)
func (*HealthCheck) UnmarshalJSON ¶
func (m *HealthCheck) UnmarshalJSON(b []byte) error
type HealthCheckHTTPConfig ¶
type HealthCheckHTTPSConfig ¶
type HealthCheckLdapConfig ¶
type HealthCheckLdapConfig struct {
}
type HealthCheckMysqlConfig ¶
type HealthCheckMysqlConfig struct {
User string `json:"user"`
}
type HealthCheckPgsqlConfig ¶
type HealthCheckPgsqlConfig struct {
User string `json:"user"`
}
type HealthCheckRedisConfig ¶
type HealthCheckRedisConfig struct {
}
type HealthCheckTCPConfig ¶
type HealthCheckTCPConfig struct {
}
type Instance ¶
type Instance struct {
ID string `json:"id"`
// Status
//
// Default value: unknown
Status InstanceStatus `json:"status"`
IPAddress string `json:"ip_address"`
Region scw.Region `json:"region"`
}
type InstanceStatus ¶
type InstanceStatus string
func (InstanceStatus) MarshalJSON ¶
func (enum InstanceStatus) MarshalJSON() ([]byte, error)
func (InstanceStatus) String ¶
func (enum InstanceStatus) String() string
func (*InstanceStatus) UnmarshalJSON ¶
func (enum *InstanceStatus) UnmarshalJSON(data []byte) error
type Lb ¶
type Lb struct {
ID string `json:"id"`
Name string `json:"name"`
Description string `json:"description"`
// Status
//
// Default value: unknown
Status LbStatus `json:"status"`
Instances []*Instance `json:"instances"`
OrganizationID string `json:"organization_id"`
IP []*IP `json:"ip"`
Tags []string `json:"tags"`
FrontendCount int32 `json:"frontend_count"`
BackendCount int32 `json:"backend_count"`
Type string `json:"type"`
Region scw.Region `json:"region"`
}
type LbStats ¶
type LbStats struct {
// BackendServersStats list stats object of your loadbalancer (See the BackendServerStats object description)
BackendServersStats []*BackendServerStats `json:"backend_servers_stats"`
}
type LbType ¶
type LbType struct {
Name string `json:"name"`
// StockStatus
//
// Default value: unknown
StockStatus LbTypeStock `json:"stock_status"`
Description string `json:"description"`
Region scw.Region `json:"region"`
}
type LbTypeStock ¶
type LbTypeStock string
func (LbTypeStock) MarshalJSON ¶
func (enum LbTypeStock) MarshalJSON() ([]byte, error)
func (LbTypeStock) String ¶
func (enum LbTypeStock) String() string
func (*LbTypeStock) UnmarshalJSON ¶
func (enum *LbTypeStock) UnmarshalJSON(data []byte) error
type ListACLRequestOrderBy ¶
type ListACLRequestOrderBy string
func (ListACLRequestOrderBy) MarshalJSON ¶
func (enum ListACLRequestOrderBy) MarshalJSON() ([]byte, error)
func (ListACLRequestOrderBy) String ¶
func (enum ListACLRequestOrderBy) String() string
func (*ListACLRequestOrderBy) UnmarshalJSON ¶
func (enum *ListACLRequestOrderBy) UnmarshalJSON(data []byte) error
type ListACLResponse ¶
type ListACLResponse struct {
// ACLs list of Acl object (see Acl object description)
ACLs []*ACL `json:"acls"`
// TotalCount result count
TotalCount uint32 `json:"total_count"`
}
func (*ListACLResponse) UnsafeAppend ¶
func (r *ListACLResponse) UnsafeAppend(res interface{}) (int, scw.SdkError)
UnsafeAppend should not be used Internal usage only
func (*ListACLResponse) UnsafeGetTotalCount ¶
func (r *ListACLResponse) UnsafeGetTotalCount() int
UnsafeGetTotalCount should not be used Internal usage only
type ListACLsRequest ¶
type ListACLsRequest struct {
Region scw.Region `json:"-"`
// FrontendID iD of your frontend
FrontendID string `json:"-"`
// OrderBy you can order the response by created_at asc/desc or name asc/desc
//
// Default value: created_at_asc
OrderBy ListACLRequestOrderBy `json:"-"`
// Page page number
Page *int32 `json:"-"`
// PageSize set the maximum list size
PageSize *int32 `json:"-"`
// Name filter acl per name
Name *string `json:"-"`
}
type ListBackendsRequest ¶
type ListBackendsRequest struct {
Region scw.Region `json:"-"`
// LbID load Balancer ID
LbID string `json:"-"`
// Name use this to search by name
Name *string `json:"-"`
// OrderBy choose order of response
//
// Default value: created_at_asc
OrderBy ListBackendsRequestOrderBy `json:"-"`
// Page page number
Page *int32 `json:"-"`
// PageSize set the maximum list sizes
PageSize *int32 `json:"-"`
}
type ListBackendsRequestOrderBy ¶
type ListBackendsRequestOrderBy string
func (ListBackendsRequestOrderBy) MarshalJSON ¶
func (enum ListBackendsRequestOrderBy) MarshalJSON() ([]byte, error)
func (ListBackendsRequestOrderBy) String ¶
func (enum ListBackendsRequestOrderBy) String() string
func (*ListBackendsRequestOrderBy) UnmarshalJSON ¶
func (enum *ListBackendsRequestOrderBy) UnmarshalJSON(data []byte) error
type ListBackendsResponse ¶
type ListBackendsResponse struct {
// Backends list Backend objects of a Load Balancer
Backends []*Backend `json:"backends"`
// TotalCount total count, wihtout pagination
TotalCount uint32 `json:"total_count"`
}
func (*ListBackendsResponse) UnsafeAppend ¶
func (r *ListBackendsResponse) UnsafeAppend(res interface{}) (int, scw.SdkError)
UnsafeAppend should not be used Internal usage only
func (*ListBackendsResponse) UnsafeGetTotalCount ¶
func (r *ListBackendsResponse) UnsafeGetTotalCount() int
UnsafeGetTotalCount should not be used Internal usage only
type ListCertificatesRequest ¶
type ListCertificatesRequest struct {
Region scw.Region `json:"-"`
// LbID load Balancer ID
LbID string `json:"-"`
// OrderBy you can order the response by created_at asc/desc or name asc/desc
//
// Default value: created_at_asc
OrderBy ListCertificatesRequestOrderBy `json:"-"`
// Page page number
Page *int32 `json:"-"`
// PageSize set the maximum list size
PageSize *int32 `json:"-"`
// Name use this to search by name
Name *string `json:"-"`
}
type ListCertificatesRequestOrderBy ¶
type ListCertificatesRequestOrderBy string
func (ListCertificatesRequestOrderBy) MarshalJSON ¶
func (enum ListCertificatesRequestOrderBy) MarshalJSON() ([]byte, error)
func (ListCertificatesRequestOrderBy) String ¶
func (enum ListCertificatesRequestOrderBy) String() string
func (*ListCertificatesRequestOrderBy) UnmarshalJSON ¶
func (enum *ListCertificatesRequestOrderBy) UnmarshalJSON(data []byte) error
type ListCertificatesResponse ¶
type ListCertificatesResponse struct {
Certificates []*Certificate `json:"certificates"`
TotalCount uint32 `json:"total_count"`
}
func (*ListCertificatesResponse) UnsafeAppend ¶
func (r *ListCertificatesResponse) UnsafeAppend(res interface{}) (int, scw.SdkError)
UnsafeAppend should not be used Internal usage only
func (*ListCertificatesResponse) UnsafeGetTotalCount ¶
func (r *ListCertificatesResponse) UnsafeGetTotalCount() int
UnsafeGetTotalCount should not be used Internal usage only
type ListFrontendsRequest ¶
type ListFrontendsRequest struct {
Region scw.Region `json:"-"`
// LbID load Balancer ID
LbID string `json:"-"`
// Name use this to search by name
Name *string `json:"-"`
// OrderBy response order
//
// Default value: created_at_asc
OrderBy ListFrontendsRequestOrderBy `json:"-"`
// Page page number
Page *int32 `json:"-"`
// PageSize set the maximum list sizes
PageSize *int32 `json:"-"`
}
type ListFrontendsRequestOrderBy ¶
type ListFrontendsRequestOrderBy string
func (ListFrontendsRequestOrderBy) MarshalJSON ¶
func (enum ListFrontendsRequestOrderBy) MarshalJSON() ([]byte, error)
func (ListFrontendsRequestOrderBy) String ¶
func (enum ListFrontendsRequestOrderBy) String() string
func (*ListFrontendsRequestOrderBy) UnmarshalJSON ¶
func (enum *ListFrontendsRequestOrderBy) UnmarshalJSON(data []byte) error
type ListFrontendsResponse ¶
type ListFrontendsResponse struct {
// Frontends list frontends object of your loadbalancer
Frontends []*Frontend `json:"frontends"`
// TotalCount total count, wihtout pagination
TotalCount uint32 `json:"total_count"`
}
func (*ListFrontendsResponse) UnsafeAppend ¶
func (r *ListFrontendsResponse) UnsafeAppend(res interface{}) (int, scw.SdkError)
UnsafeAppend should not be used Internal usage only
func (*ListFrontendsResponse) UnsafeGetTotalCount ¶
func (r *ListFrontendsResponse) UnsafeGetTotalCount() int
UnsafeGetTotalCount should not be used Internal usage only
type ListIPsRequest ¶
type ListIPsResponse ¶
type ListIPsResponse struct {
// IPs list IP address object
IPs []*IP `json:"ips"`
// TotalCount total count, wihtout pagination
TotalCount uint32 `json:"total_count"`
}
func (*ListIPsResponse) UnsafeAppend ¶
func (r *ListIPsResponse) UnsafeAppend(res interface{}) (int, scw.SdkError)
UnsafeAppend should not be used Internal usage only
func (*ListIPsResponse) UnsafeGetTotalCount ¶
func (r *ListIPsResponse) UnsafeGetTotalCount() int
UnsafeGetTotalCount should not be used Internal usage only
type ListLbTypesRequest ¶
type ListLbTypesResponse ¶
type ListLbTypesResponse struct {
LbTypes []*LbType `json:"lb_types"`
TotalCount uint32 `json:"total_count"`
}
func (*ListLbTypesResponse) UnsafeAppend ¶
func (r *ListLbTypesResponse) UnsafeAppend(res interface{}) (int, scw.SdkError)
UnsafeAppend should not be used Internal usage only
func (*ListLbTypesResponse) UnsafeGetTotalCount ¶
func (r *ListLbTypesResponse) UnsafeGetTotalCount() int
UnsafeGetTotalCount should not be used Internal usage only
type ListLbsRequest ¶
type ListLbsRequestOrderBy ¶
type ListLbsRequestOrderBy string
func (ListLbsRequestOrderBy) MarshalJSON ¶
func (enum ListLbsRequestOrderBy) MarshalJSON() ([]byte, error)
func (ListLbsRequestOrderBy) String ¶
func (enum ListLbsRequestOrderBy) String() string
func (*ListLbsRequestOrderBy) UnmarshalJSON ¶
func (enum *ListLbsRequestOrderBy) UnmarshalJSON(data []byte) error
type ListLbsResponse ¶
func (*ListLbsResponse) UnsafeAppend ¶
func (r *ListLbsResponse) UnsafeAppend(res interface{}) (int, scw.SdkError)
UnsafeAppend should not be used Internal usage only
func (*ListLbsResponse) UnsafeGetTotalCount ¶
func (r *ListLbsResponse) UnsafeGetTotalCount() int
UnsafeGetTotalCount should not be used Internal usage only
type OnMarkedDownAction ¶
type OnMarkedDownAction string
func (OnMarkedDownAction) MarshalJSON ¶
func (enum OnMarkedDownAction) MarshalJSON() ([]byte, error)
func (OnMarkedDownAction) String ¶
func (enum OnMarkedDownAction) String() string
func (*OnMarkedDownAction) UnmarshalJSON ¶
func (enum *OnMarkedDownAction) UnmarshalJSON(data []byte) error
type ReleaseIPRequest ¶
type StickySessionsType ¶
type StickySessionsType string
func (StickySessionsType) MarshalJSON ¶
func (enum StickySessionsType) MarshalJSON() ([]byte, error)
func (StickySessionsType) String ¶
func (enum StickySessionsType) String() string
func (*StickySessionsType) UnmarshalJSON ¶
func (enum *StickySessionsType) UnmarshalJSON(data []byte) error
type TypeLetsencrypt ¶
type TypeLetsencrypt struct {
Value CreateCertificateRequestLetsencryptConfig
}
type UpdateACLRequest ¶
type UpdateACLRequest struct {
Region scw.Region `json:"-"`
// ACLID iD of your ACL ressource
ACLID string `json:"-"`
// Name name of your ACL ressource
Name string `json:"name"`
// Action see the AclAction object description
Action *ACLAction `json:"action"`
// Match see the AclMatch object description
Match *ACLMatch `json:"match"`
// Index order between your Acls (ascending order, 0 is first acl executed)
Index int32 `json:"index"`
}
type UpdateBackendRequest ¶
type UpdateBackendRequest struct {
Region scw.Region `json:"-"`
// BackendID backend ID to update
BackendID string `json:"-"`
// Name resource name
Name string `json:"name"`
// ForwardProtocol backend protocol. TCP or HTTP
//
// Default value: tcp
ForwardProtocol Protocol `json:"forward_protocol"`
// ForwardPort user sessions will be forwarded to this port of backend servers
ForwardPort int32 `json:"forward_port"`
// ForwardPortAlgorithm load balancing algorithm
//
// Default value: roundrobin
ForwardPortAlgorithm ForwardPortAlgorithm `json:"forward_port_algorithm"`
// StickySessions enable cookie-based session persistence
//
// Default value: none
StickySessions StickySessionsType `json:"sticky_sessions"`
// StickySessionsCookieName cookie name for for sticky sessions
StickySessionsCookieName string `json:"sticky_sessions_cookie_name"`
// SendProxyV2 enables PROXY protocol version 2 (must be supported by backend servers)
SendProxyV2 bool `json:"send_proxy_v2"`
// TimeoutServer maximum server connection inactivity time
TimeoutServer *time.Duration `json:"timeout_server"`
// TimeoutConnect maximum initial server connection establishment time
TimeoutConnect *time.Duration `json:"timeout_connect"`
// TimeoutTunnel maximum tunnel inactivity time
TimeoutTunnel *time.Duration `json:"timeout_tunnel"`
// OnMarkedDownAction modify what occurs when a backend server is marked down
//
// Default value: on_marked_down_action_none
OnMarkedDownAction OnMarkedDownAction `json:"on_marked_down_action"`
}
func (UpdateBackendRequest) MarshalJSON ¶
func (m UpdateBackendRequest) MarshalJSON() ([]byte, error)
func (*UpdateBackendRequest) UnmarshalJSON ¶
func (m *UpdateBackendRequest) UnmarshalJSON(b []byte) error
type UpdateFrontendRequest ¶
type UpdateFrontendRequest struct {
Region scw.Region `json:"-"`
// FrontendID frontend ID
FrontendID string `json:"-"`
// Name resource name
Name string `json:"name"`
// InboundPort tCP port to listen on the front side
InboundPort int32 `json:"inbound_port"`
// BackendID backend ID
BackendID string `json:"backend_id"`
// TimeoutClient client session maximum inactivity time
TimeoutClient *time.Duration `json:"timeout_client"`
// CertificateID certificate ID
CertificateID *string `json:"certificate_id"`
}
func (UpdateFrontendRequest) MarshalJSON ¶
func (m UpdateFrontendRequest) MarshalJSON() ([]byte, error)
func (*UpdateFrontendRequest) UnmarshalJSON ¶
func (m *UpdateFrontendRequest) UnmarshalJSON(b []byte) error
type UpdateHealthCheckRequest ¶
type UpdateHealthCheckRequest struct {
Region scw.Region `json:"-"`
// BackendID backend ID
BackendID string `json:"-"`
// Port specify the port used to health check
Port int32 `json:"port"`
// CheckDelay time between two consecutive health checks
CheckDelay *time.Duration `json:"check_delay"`
// CheckTimeout additional check timeout, after the connection has been already established
CheckTimeout *time.Duration `json:"check_timeout"`
// CheckMaxRetries number of consecutive unsuccessful health checks, after wich the server will be considered dead
CheckMaxRetries int32 `json:"check_max_retries"`
// MysqlConfig the check requires MySQL >=3.22, for older version, please use TCP check
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
MysqlConfig *HealthCheckMysqlConfig `json:"mysql_config,omitempty"`
// LdapConfig the response is analyzed to find an LDAPv3 response message
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
LdapConfig *HealthCheckLdapConfig `json:"ldap_config,omitempty"`
// RedisConfig the response is analyzed to find the +PONG response message
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
RedisConfig *HealthCheckRedisConfig `json:"redis_config,omitempty"`
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
PgsqlConfig *HealthCheckPgsqlConfig `json:"pgsql_config,omitempty"`
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
TCPConfig *HealthCheckTCPConfig `json:"tcp_config,omitempty"`
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
HTTPConfig *HealthCheckHTTPConfig `json:"http_config,omitempty"`
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
HTTPSConfig *HealthCheckHTTPSConfig `json:"https_config,omitempty"`
}
func (*UpdateHealthCheckRequest) GetConfig ¶
func (m *UpdateHealthCheckRequest) GetConfig() Config
func (UpdateHealthCheckRequest) MarshalJSON ¶
func (m UpdateHealthCheckRequest) MarshalJSON() ([]byte, error)
func (*UpdateHealthCheckRequest) UnmarshalJSON ¶
func (m *UpdateHealthCheckRequest) UnmarshalJSON(b []byte) error