Documentation
¶
Overview ¶
Package lb provides methods and message types of the lb v1 API.
Index ¶
- Constants
- type ACL
- type ACLAction
- type ACLActionRedirect
- type ACLActionRedirectRedirectType
- type ACLActionType
- type ACLHTTPFilter
- type ACLMatch
- type ACLSpec
- type API
- func (s *API) AddBackendServers(req *AddBackendServersRequest, opts ...scw.RequestOption) (*Backend, error)
- func (s *API) AttachPrivateNetwork(req *AttachPrivateNetworkRequest, opts ...scw.RequestOption) (*PrivateNetwork, 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) CreateIP(req *CreateIPRequest, opts ...scw.RequestOption) (*IP, error)
- func (s *API) CreateLB(req *CreateLBRequest, opts ...scw.RequestOption) (*LB, error)
- func (s *API) CreateRoute(req *CreateRouteRequest, opts ...scw.RequestOption) (*Route, error)
- func (s *API) CreateSubscriber(req *CreateSubscriberRequest, opts ...scw.RequestOption) (*Subscriber, 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) DeleteRoute(req *DeleteRouteRequest, opts ...scw.RequestOption) error
- func (s *API) DeleteSubscriber(req *DeleteSubscriberRequest, opts ...scw.RequestOption) error
- func (s *API) DetachPrivateNetwork(req *DetachPrivateNetworkRequest, 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)deprecated
- func (s *API) GetRoute(req *GetRouteRequest, opts ...scw.RequestOption) (*Route, error)
- func (s *API) GetSubscriber(req *GetSubscriberRequest, opts ...scw.RequestOption) (*Subscriber, error)
- func (s *API) ListACLs(req *ListACLsRequest, opts ...scw.RequestOption) (*ListACLResponse, error)
- func (s *API) ListBackendStats(req *ListBackendStatsRequest, opts ...scw.RequestOption) (*ListBackendStatsResponse, 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) ListLBPrivateNetworks(req *ListLBPrivateNetworksRequest, opts ...scw.RequestOption) (*ListLBPrivateNetworksResponse, 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) ListRoutes(req *ListRoutesRequest, opts ...scw.RequestOption) (*ListRoutesResponse, error)
- func (s *API) ListSubscriber(req *ListSubscriberRequest, opts ...scw.RequestOption) (*ListSubscriberResponse, error)
- func (s *API) MigrateLB(req *MigrateLBRequest, opts ...scw.RequestOption) (*LB, error)
- func (s *API) Regions() []scw.Region
- 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) SubscribeToLB(req *SubscribeToLBRequest, opts ...scw.RequestOption) (*LB, error)
- func (s *API) UnsubscribeFromLB(req *UnsubscribeFromLBRequest, opts ...scw.RequestOption) (*LB, 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)
- func (s *API) UpdateRoute(req *UpdateRouteRequest, opts ...scw.RequestOption) (*Route, error)
- func (s *API) UpdateSubscriber(req *UpdateSubscriberRequest, opts ...scw.RequestOption) (*Subscriber, error)
- func (s *API) WaitForLb(req *WaitForLBRequest, opts ...scw.RequestOption) (*LB, error)
- type AddBackendServersRequest
- type AttachPrivateNetworkRequest
- type Backend
- type BackendServerStats
- type BackendServerStatsHealthCheckStatus
- type BackendServerStatsServerState
- type Certificate
- type CertificateStatus
- type CertificateType
- type CreateACLRequest
- type CreateBackendRequest
- type CreateCertificateRequest
- type CreateCertificateRequestCustomCertificate
- type CreateCertificateRequestLetsencryptConfig
- type CreateFrontendRequest
- type CreateIPRequest
- type CreateLBRequest
- type CreateRouteRequest
- type CreateSubscriberRequest
- type DeleteACLRequest
- type DeleteBackendRequest
- type DeleteCertificateRequest
- type DeleteFrontendRequest
- type DeleteLBRequest
- type DeleteRouteRequest
- type DeleteSubscriberRequest
- type DetachPrivateNetworkRequest
- type ForwardPortAlgorithm
- type Frontend
- type GetACLRequest
- type GetBackendRequest
- type GetCertificateRequest
- type GetFrontendRequest
- type GetIPRequest
- type GetLBRequest
- type GetLBStatsRequest
- type GetRouteRequest
- type GetSubscriberRequest
- 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 ListBackendStatsRequest
- type ListBackendStatsResponse
- type ListBackendsRequest
- type ListBackendsRequestOrderBy
- type ListBackendsResponse
- type ListCertificatesRequest
- type ListCertificatesRequestOrderBy
- type ListCertificatesResponse
- type ListFrontendsRequest
- type ListFrontendsRequestOrderBy
- type ListFrontendsResponse
- type ListIPsRequest
- type ListIPsResponse
- type ListLBPrivateNetworksRequest
- type ListLBPrivateNetworksResponse
- type ListLBTypesRequest
- type ListLBTypesResponse
- type ListLBsRequest
- type ListLBsRequestOrderBy
- type ListLBsResponse
- type ListPrivateNetworksRequestOrderBy
- type ListRoutesRequest
- type ListRoutesRequestOrderBy
- type ListRoutesResponse
- type ListSubscriberRequest
- type ListSubscriberRequestOrderBy
- type ListSubscriberResponse
- type MigrateLBRequest
- type OnMarkedDownAction
- type PrivateNetwork
- type PrivateNetworkDHCPConfig
- type PrivateNetworkStaticConfig
- type PrivateNetworkStatus
- type Protocol
- type ProxyProtocol
- type ReleaseIPRequest
- type RemoveBackendServersRequest
- type Route
- type RouteMatch
- type SSLCompatibilityLevel
- type SetACLsResponse
- type SetBackendServersRequest
- type StickySessionsType
- type SubscribeToLBRequest
- type Subscriber
- type SubscriberEmailConfig
- type SubscriberWebhookConfig
- type UnsubscribeFromLBRequest
- type UpdateACLRequest
- type UpdateBackendRequest
- type UpdateCertificateRequest
- type UpdateFrontendRequest
- type UpdateHealthCheckRequest
- type UpdateIPRequest
- type UpdateLBRequest
- type UpdateRouteRequest
- type UpdateSubscriberRequest
- type WaitForLBRequest
- type ZonedAPI
- func (s *ZonedAPI) AddBackendServers(req *ZonedAPIAddBackendServersRequest, opts ...scw.RequestOption) (*Backend, error)
- func (s *ZonedAPI) AttachPrivateNetwork(req *ZonedAPIAttachPrivateNetworkRequest, opts ...scw.RequestOption) (*PrivateNetwork, error)
- func (s *ZonedAPI) CreateACL(req *ZonedAPICreateACLRequest, opts ...scw.RequestOption) (*ACL, error)
- func (s *ZonedAPI) CreateBackend(req *ZonedAPICreateBackendRequest, opts ...scw.RequestOption) (*Backend, error)
- func (s *ZonedAPI) CreateCertificate(req *ZonedAPICreateCertificateRequest, opts ...scw.RequestOption) (*Certificate, error)
- func (s *ZonedAPI) CreateFrontend(req *ZonedAPICreateFrontendRequest, opts ...scw.RequestOption) (*Frontend, error)
- func (s *ZonedAPI) CreateIP(req *ZonedAPICreateIPRequest, opts ...scw.RequestOption) (*IP, error)
- func (s *ZonedAPI) CreateLB(req *ZonedAPICreateLBRequest, opts ...scw.RequestOption) (*LB, error)
- func (s *ZonedAPI) CreateRoute(req *ZonedAPICreateRouteRequest, opts ...scw.RequestOption) (*Route, error)
- func (s *ZonedAPI) CreateSubscriber(req *ZonedAPICreateSubscriberRequest, opts ...scw.RequestOption) (*Subscriber, error)
- func (s *ZonedAPI) DeleteACL(req *ZonedAPIDeleteACLRequest, opts ...scw.RequestOption) error
- func (s *ZonedAPI) DeleteBackend(req *ZonedAPIDeleteBackendRequest, opts ...scw.RequestOption) error
- func (s *ZonedAPI) DeleteCertificate(req *ZonedAPIDeleteCertificateRequest, opts ...scw.RequestOption) error
- func (s *ZonedAPI) DeleteFrontend(req *ZonedAPIDeleteFrontendRequest, opts ...scw.RequestOption) error
- func (s *ZonedAPI) DeleteLB(req *ZonedAPIDeleteLBRequest, opts ...scw.RequestOption) error
- func (s *ZonedAPI) DeleteRoute(req *ZonedAPIDeleteRouteRequest, opts ...scw.RequestOption) error
- func (s *ZonedAPI) DeleteSubscriber(req *ZonedAPIDeleteSubscriberRequest, opts ...scw.RequestOption) error
- func (s *ZonedAPI) DetachPrivateNetwork(req *ZonedAPIDetachPrivateNetworkRequest, opts ...scw.RequestOption) error
- func (s *ZonedAPI) GetACL(req *ZonedAPIGetACLRequest, opts ...scw.RequestOption) (*ACL, error)
- func (s *ZonedAPI) GetBackend(req *ZonedAPIGetBackendRequest, opts ...scw.RequestOption) (*Backend, error)
- func (s *ZonedAPI) GetCertificate(req *ZonedAPIGetCertificateRequest, opts ...scw.RequestOption) (*Certificate, error)
- func (s *ZonedAPI) GetFrontend(req *ZonedAPIGetFrontendRequest, opts ...scw.RequestOption) (*Frontend, error)
- func (s *ZonedAPI) GetIP(req *ZonedAPIGetIPRequest, opts ...scw.RequestOption) (*IP, error)
- func (s *ZonedAPI) GetLB(req *ZonedAPIGetLBRequest, opts ...scw.RequestOption) (*LB, error)
- func (s *ZonedAPI) GetLBStats(req *ZonedAPIGetLBStatsRequest, opts ...scw.RequestOption) (*LBStats, error)deprecated
- func (s *ZonedAPI) GetRoute(req *ZonedAPIGetRouteRequest, opts ...scw.RequestOption) (*Route, error)
- func (s *ZonedAPI) GetSubscriber(req *ZonedAPIGetSubscriberRequest, opts ...scw.RequestOption) (*Subscriber, error)
- func (s *ZonedAPI) ListACLs(req *ZonedAPIListACLsRequest, opts ...scw.RequestOption) (*ListACLResponse, error)
- func (s *ZonedAPI) ListBackendStats(req *ZonedAPIListBackendStatsRequest, opts ...scw.RequestOption) (*ListBackendStatsResponse, error)
- func (s *ZonedAPI) ListBackends(req *ZonedAPIListBackendsRequest, opts ...scw.RequestOption) (*ListBackendsResponse, error)
- func (s *ZonedAPI) ListCertificates(req *ZonedAPIListCertificatesRequest, opts ...scw.RequestOption) (*ListCertificatesResponse, error)
- func (s *ZonedAPI) ListFrontends(req *ZonedAPIListFrontendsRequest, opts ...scw.RequestOption) (*ListFrontendsResponse, error)
- func (s *ZonedAPI) ListIPs(req *ZonedAPIListIPsRequest, opts ...scw.RequestOption) (*ListIPsResponse, error)
- func (s *ZonedAPI) ListLBPrivateNetworks(req *ZonedAPIListLBPrivateNetworksRequest, opts ...scw.RequestOption) (*ListLBPrivateNetworksResponse, error)
- func (s *ZonedAPI) ListLBTypes(req *ZonedAPIListLBTypesRequest, opts ...scw.RequestOption) (*ListLBTypesResponse, error)
- func (s *ZonedAPI) ListLBs(req *ZonedAPIListLBsRequest, opts ...scw.RequestOption) (*ListLBsResponse, error)
- func (s *ZonedAPI) ListRoutes(req *ZonedAPIListRoutesRequest, opts ...scw.RequestOption) (*ListRoutesResponse, error)
- func (s *ZonedAPI) ListSubscriber(req *ZonedAPIListSubscriberRequest, opts ...scw.RequestOption) (*ListSubscriberResponse, error)
- func (s *ZonedAPI) MigrateLB(req *ZonedAPIMigrateLBRequest, opts ...scw.RequestOption) (*LB, error)
- func (s *ZonedAPI) ReleaseIP(req *ZonedAPIReleaseIPRequest, opts ...scw.RequestOption) error
- func (s *ZonedAPI) RemoveBackendServers(req *ZonedAPIRemoveBackendServersRequest, opts ...scw.RequestOption) (*Backend, error)
- func (s *ZonedAPI) SetACLs(req *ZonedAPISetACLsRequest, opts ...scw.RequestOption) (*SetACLsResponse, error)
- func (s *ZonedAPI) SetBackendServers(req *ZonedAPISetBackendServersRequest, opts ...scw.RequestOption) (*Backend, error)
- func (s *ZonedAPI) SubscribeToLB(req *ZonedAPISubscribeToLBRequest, opts ...scw.RequestOption) (*LB, error)
- func (s *ZonedAPI) UnsubscribeFromLB(req *ZonedAPIUnsubscribeFromLBRequest, opts ...scw.RequestOption) (*LB, error)
- func (s *ZonedAPI) UpdateACL(req *ZonedAPIUpdateACLRequest, opts ...scw.RequestOption) (*ACL, error)
- func (s *ZonedAPI) UpdateBackend(req *ZonedAPIUpdateBackendRequest, opts ...scw.RequestOption) (*Backend, error)
- func (s *ZonedAPI) UpdateCertificate(req *ZonedAPIUpdateCertificateRequest, opts ...scw.RequestOption) (*Certificate, error)
- func (s *ZonedAPI) UpdateFrontend(req *ZonedAPIUpdateFrontendRequest, opts ...scw.RequestOption) (*Frontend, error)
- func (s *ZonedAPI) UpdateHealthCheck(req *ZonedAPIUpdateHealthCheckRequest, opts ...scw.RequestOption) (*HealthCheck, error)
- func (s *ZonedAPI) UpdateIP(req *ZonedAPIUpdateIPRequest, opts ...scw.RequestOption) (*IP, error)
- func (s *ZonedAPI) UpdateLB(req *ZonedAPIUpdateLBRequest, opts ...scw.RequestOption) (*LB, error)
- func (s *ZonedAPI) UpdateRoute(req *ZonedAPIUpdateRouteRequest, opts ...scw.RequestOption) (*Route, error)
- func (s *ZonedAPI) UpdateSubscriber(req *ZonedAPIUpdateSubscriberRequest, opts ...scw.RequestOption) (*Subscriber, error)
- func (s *ZonedAPI) WaitForLBCertificate(req *ZonedAPIWaitForLBCertificateRequest, opts ...scw.RequestOption) (*Certificate, error)
- func (s *ZonedAPI) WaitForLBPN(req *ZonedAPIWaitForLBPNRequest, opts ...scw.RequestOption) ([]*PrivateNetwork, error)
- func (s *ZonedAPI) WaitForLb(req *ZonedAPIWaitForLBRequest, opts ...scw.RequestOption) (*LB, error)
- func (s *ZonedAPI) WaitForLbInstances(req *ZonedAPIWaitForLBInstancesRequest, opts ...scw.RequestOption) (*LB, error)
- func (s *ZonedAPI) Zones() []scw.Zone
- type ZonedAPIAddBackendServersRequest
- type ZonedAPIAttachPrivateNetworkRequest
- type ZonedAPICreateACLRequest
- type ZonedAPICreateBackendRequest
- type ZonedAPICreateCertificateRequest
- type ZonedAPICreateFrontendRequest
- type ZonedAPICreateIPRequest
- type ZonedAPICreateLBRequest
- type ZonedAPICreateRouteRequest
- type ZonedAPICreateSubscriberRequest
- type ZonedAPIDeleteACLRequest
- type ZonedAPIDeleteBackendRequest
- type ZonedAPIDeleteCertificateRequest
- type ZonedAPIDeleteFrontendRequest
- type ZonedAPIDeleteLBRequest
- type ZonedAPIDeleteRouteRequest
- type ZonedAPIDeleteSubscriberRequest
- type ZonedAPIDetachPrivateNetworkRequest
- type ZonedAPIGetACLRequest
- type ZonedAPIGetBackendRequest
- type ZonedAPIGetCertificateRequest
- type ZonedAPIGetFrontendRequest
- type ZonedAPIGetIPRequest
- type ZonedAPIGetLBRequest
- type ZonedAPIGetLBStatsRequest
- type ZonedAPIGetRouteRequest
- type ZonedAPIGetSubscriberRequest
- type ZonedAPIListACLsRequest
- type ZonedAPIListBackendStatsRequest
- type ZonedAPIListBackendsRequest
- type ZonedAPIListCertificatesRequest
- type ZonedAPIListFrontendsRequest
- type ZonedAPIListIPsRequest
- type ZonedAPIListLBPrivateNetworksRequest
- type ZonedAPIListLBTypesRequest
- type ZonedAPIListLBsRequest
- type ZonedAPIListRoutesRequest
- type ZonedAPIListSubscriberRequest
- type ZonedAPIMigrateLBRequest
- type ZonedAPIReleaseIPRequest
- type ZonedAPIRemoveBackendServersRequest
- type ZonedAPISetACLsRequest
- type ZonedAPISetBackendServersRequest
- type ZonedAPISubscribeToLBRequest
- type ZonedAPIUnsubscribeFromLBRequest
- type ZonedAPIUpdateACLRequest
- type ZonedAPIUpdateBackendRequest
- type ZonedAPIUpdateCertificateRequest
- type ZonedAPIUpdateFrontendRequest
- type ZonedAPIUpdateHealthCheckRequest
- type ZonedAPIUpdateIPRequest
- type ZonedAPIUpdateLBRequest
- type ZonedAPIUpdateRouteRequest
- type ZonedAPIUpdateSubscriberRequest
- type ZonedAPIWaitForLBCertificateRequest
- type ZonedAPIWaitForLBInstancesRequest
- type ZonedAPIWaitForLBPNRequest
- type ZonedAPIWaitForLBRequest
Constants ¶
const ( // ACLActionRedirectRedirectTypeLocation is [insert doc]. ACLActionRedirectRedirectTypeLocation = ACLActionRedirectRedirectType("location") // ACLActionRedirectRedirectTypeScheme is [insert doc]. ACLActionRedirectRedirectTypeScheme = ACLActionRedirectRedirectType("scheme") )
const ( // ACLActionTypeAllow is [insert doc]. ACLActionTypeAllow = ACLActionType("allow") // ACLActionTypeDeny is [insert doc]. ACLActionTypeDeny = ACLActionType("deny") // ACLActionTypeRedirect is [insert doc]. ACLActionTypeRedirect = ACLActionType("redirect") )
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") // ACLHTTPFilterHTTPHeaderMatch is [insert doc]. ACLHTTPFilterHTTPHeaderMatch = ACLHTTPFilter("http_header_match") )
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 ( // CertificateTypeLetsencryt is [insert doc]. CertificateTypeLetsencryt = CertificateType("letsencryt") // CertificateTypeCustom is [insert doc]. CertificateTypeCustom = CertificateType("custom") )
const ( // ForwardPortAlgorithmRoundrobin is [insert doc]. ForwardPortAlgorithmRoundrobin = ForwardPortAlgorithm("roundrobin") // ForwardPortAlgorithmLeastconn is [insert doc]. ForwardPortAlgorithmLeastconn = ForwardPortAlgorithm("leastconn") // ForwardPortAlgorithmFirst is [insert doc]. ForwardPortAlgorithmFirst = ForwardPortAlgorithm("first") )
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") // InstanceStatusMigrating is [insert doc]. InstanceStatusMigrating = InstanceStatus("migrating") )
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") // LBStatusMigrating is [insert doc]. LBStatusMigrating = LBStatus("migrating") // LBStatusToCreate is [insert doc]. LBStatusToCreate = LBStatus("to_create") // LBStatusCreating is [insert doc]. LBStatusCreating = LBStatus("creating") // LBStatusToDelete is [insert doc]. LBStatusToDelete = LBStatus("to_delete") // LBStatusDeleting is [insert doc]. LBStatusDeleting = LBStatus("deleting") )
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 ( // ListPrivateNetworksRequestOrderByCreatedAtAsc is [insert doc]. ListPrivateNetworksRequestOrderByCreatedAtAsc = ListPrivateNetworksRequestOrderBy("created_at_asc") // ListPrivateNetworksRequestOrderByCreatedAtDesc is [insert doc]. ListPrivateNetworksRequestOrderByCreatedAtDesc = ListPrivateNetworksRequestOrderBy("created_at_desc") )
const ( // ListRoutesRequestOrderByCreatedAtAsc is [insert doc]. ListRoutesRequestOrderByCreatedAtAsc = ListRoutesRequestOrderBy("created_at_asc") // ListRoutesRequestOrderByCreatedAtDesc is [insert doc]. ListRoutesRequestOrderByCreatedAtDesc = ListRoutesRequestOrderBy("created_at_desc") )
const ( // ListSubscriberRequestOrderByCreatedAtAsc is [insert doc]. ListSubscriberRequestOrderByCreatedAtAsc = ListSubscriberRequestOrderBy("created_at_asc") // ListSubscriberRequestOrderByCreatedAtDesc is [insert doc]. ListSubscriberRequestOrderByCreatedAtDesc = ListSubscriberRequestOrderBy("created_at_desc") // ListSubscriberRequestOrderByNameAsc is [insert doc]. ListSubscriberRequestOrderByNameAsc = ListSubscriberRequestOrderBy("name_asc") // ListSubscriberRequestOrderByNameDesc is [insert doc]. ListSubscriberRequestOrderByNameDesc = ListSubscriberRequestOrderBy("name_desc") )
const ( // OnMarkedDownActionOnMarkedDownActionNone is [insert doc]. OnMarkedDownActionOnMarkedDownActionNone = OnMarkedDownAction("on_marked_down_action_none") // OnMarkedDownActionShutdownSessions is [insert doc]. OnMarkedDownActionShutdownSessions = OnMarkedDownAction("shutdown_sessions") )
const ( // PrivateNetworkStatusUnknown is [insert doc]. PrivateNetworkStatusUnknown = PrivateNetworkStatus("unknown") // PrivateNetworkStatusReady is [insert doc]. PrivateNetworkStatusReady = PrivateNetworkStatus("ready") // PrivateNetworkStatusPending is [insert doc]. PrivateNetworkStatusPending = PrivateNetworkStatus("pending") // PrivateNetworkStatusError is [insert doc]. PrivateNetworkStatusError = PrivateNetworkStatus("error") )
const ( // ProtocolTCP is [insert doc]. ProtocolTCP = Protocol("tcp") // ProtocolHTTP is [insert doc]. ProtocolHTTP = Protocol("http") )
const ( // ProxyProtocolProxyProtocolUnknown is [insert doc]. ProxyProtocolProxyProtocolUnknown = ProxyProtocol("proxy_protocol_unknown") // ProxyProtocolProxyProtocolNone is [insert doc]. ProxyProtocolProxyProtocolNone = ProxyProtocol("proxy_protocol_none") // ProxyProtocolProxyProtocolV1 is [insert doc]. ProxyProtocolProxyProtocolV1 = ProxyProtocol("proxy_protocol_v1") // ProxyProtocolProxyProtocolV2 is [insert doc]. ProxyProtocolProxyProtocolV2 = ProxyProtocol("proxy_protocol_v2") // ProxyProtocolProxyProtocolV2Ssl is [insert doc]. ProxyProtocolProxyProtocolV2Ssl = ProxyProtocol("proxy_protocol_v2_ssl") // ProxyProtocolProxyProtocolV2SslCn is [insert doc]. ProxyProtocolProxyProtocolV2SslCn = ProxyProtocol("proxy_protocol_v2_ssl_cn") )
const ( // SSLCompatibilityLevelSslCompatibilityLevelUnknown is [insert doc]. SSLCompatibilityLevelSslCompatibilityLevelUnknown = SSLCompatibilityLevel("ssl_compatibility_level_unknown") // SSLCompatibilityLevelSslCompatibilityLevelIntermediate is [insert doc]. SSLCompatibilityLevelSslCompatibilityLevelIntermediate = SSLCompatibilityLevel("ssl_compatibility_level_intermediate") // SSLCompatibilityLevelSslCompatibilityLevelModern is [insert doc]. SSLCompatibilityLevelSslCompatibilityLevelModern = SSLCompatibilityLevel("ssl_compatibility_level_modern") // SSLCompatibilityLevelSslCompatibilityLevelOld is [insert doc]. SSLCompatibilityLevelSslCompatibilityLevelOld = SSLCompatibilityLevel("ssl_compatibility_level_old") )
const ( // StickySessionsTypeNone is [insert doc]. StickySessionsTypeNone = StickySessionsType("none") // StickySessionsTypeCookie is [insert doc]. StickySessionsTypeCookie = StickySessionsType("cookie") // StickySessionsTypeTable is [insert doc]. StickySessionsTypeTable = StickySessionsType("table") )
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: the ACL match rule. At least `ip_subnet` or `http_filter` and `http_filter_value` are required
Match *ACLMatch `json:"match"`
// Action: action to undertake when an ACL filter matches
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"`
// CreatedAt: date at which the ACL was created
CreatedAt *time.Time `json:"created_at"`
// UpdatedAt: date at which the ACL was last updated
UpdatedAt *time.Time `json:"updated_at"`
// Description: description of your ACL ressource
Description string `json:"description"`
}
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: the action type
//
// Default value: allow
Type ACLActionType `json:"type"`
// Redirect: redirect parameters when using an ACL with `redirect` action
Redirect *ACLActionRedirect `json:"redirect"`
}
ACLAction: acl action
type ACLActionRedirect ¶
type ACLActionRedirect struct {
// Type: redirect type
//
// Default value: location
Type ACLActionRedirectRedirectType `json:"type"`
// Target: redirect target (target URL for `location`, or target `scheme`)
//
// An URL can be used in case of a location redirect (e.g. `https://scaleway.com` will redirect to this same URL).
// A scheme name (e.g. `https`, `http`, `ftp`, `git`) will replace the request's original scheme. This can be useful to implement HTTP to HTTPS redirects.
// Placeholders can be used when using a `location` redirect in order to insert original request's parts, these are:
// - `{{ host }}` for the current request's Host header
// - `{{ query }}` for the current request's query string
// - `{{ path }}` for the current request's URL path
// - `{{ scheme }}` for the current request's scheme
//
Target string `json:"target"`
// Code: HTTP redirect code to use. Valid values are 301, 302, 303, 307 and 308. Default value is 302
Code *int32 `json:"code"`
}
ACLActionRedirect: acl action redirect
type ACLActionRedirectRedirectType ¶
type ACLActionRedirectRedirectType string
func (ACLActionRedirectRedirectType) MarshalJSON ¶
func (enum ACLActionRedirectRedirectType) MarshalJSON() ([]byte, error)
func (ACLActionRedirectRedirectType) String ¶
func (enum ACLActionRedirectRedirectType) String() string
func (*ACLActionRedirectRedirectType) UnmarshalJSON ¶
func (enum *ACLActionRedirectRedirectType) UnmarshalJSON(data []byte) error
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: a list of IPs or CIDR v4/v6 addresses of the client of the session to match
IPSubnet []*string `json:"ip_subnet"`
// HTTPFilter: the HTTP filter to match
//
// The HTTP filter to match. This filter is supported only if your backend supports HTTP forwarding.
// It extracts the request's URL path, which starts at the first slash and ends before the question mark (without the host part).
//
// Default value: acl_http_filter_none
HTTPFilter ACLHTTPFilter `json:"http_filter"`
// HTTPFilterValue: a list of possible values to match for the given HTTP filter
HTTPFilterValue []*string `json:"http_filter_value"`
// HTTPFilterOption: a exra parameter. You can use this field with http_header_match acl type to set the header name to filter
HTTPFilterOption *string `json:"http_filter_option"`
// Invert: if set to `true`, the ACL matching condition will be of type "UNLESS"
Invert bool `json:"invert"`
}
ACLMatch: acl match
type ACLSpec ¶
type ACLSpec struct {
// Name: name of your ACL resource
Name string `json:"name"`
// Action: action to undertake when an ACL filter matches
Action *ACLAction `json:"action"`
// Match: the ACL match rule. At least `ip_subnet` or `http_filter` and `http_filter_value` are required
Match *ACLMatch `json:"match"`
// Index: order between your Acls (ascending order, 0 is first acl executed)
Index int32 `json:"index"`
// Description: description of your ACL ressource
Description string `json:"description"`
}
ACLSpec: acl spec
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)
AddBackendServers: add a set of servers in a given backend
func (*API) AttachPrivateNetwork ¶
func (s *API) AttachPrivateNetwork(req *AttachPrivateNetworkRequest, opts ...scw.RequestOption) (*PrivateNetwork, error)
AttachPrivateNetwork: add load balancer on instance private network
func (*API) CreateACL ¶
func (s *API) CreateACL(req *CreateACLRequest, opts ...scw.RequestOption) (*ACL, error)
CreateACL: create an ACL for a given frontend
func (*API) CreateBackend ¶
func (s *API) CreateBackend(req *CreateBackendRequest, opts ...scw.RequestOption) (*Backend, error)
CreateBackend: create a backend in a given load balancer
func (*API) CreateCertificate ¶
func (s *API) CreateCertificate(req *CreateCertificateRequest, opts ...scw.RequestOption) (*Certificate, error)
CreateCertificate: create a TLS certificate
Generate a new TLS certificate using Let's Encrypt or import your certificate.
func (*API) CreateFrontend ¶
func (s *API) CreateFrontend(req *CreateFrontendRequest, opts ...scw.RequestOption) (*Frontend, error)
CreateFrontend: create a frontend in a given load balancer
func (*API) CreateIP ¶
func (s *API) CreateIP(req *CreateIPRequest, opts ...scw.RequestOption) (*IP, error)
CreateIP: create an IP
func (*API) CreateLB ¶
func (s *API) CreateLB(req *CreateLBRequest, opts ...scw.RequestOption) (*LB, error)
CreateLB: create a load balancer
func (*API) CreateRoute ¶
func (s *API) CreateRoute(req *CreateRouteRequest, opts ...scw.RequestOption) (*Route, error)
CreateRoute: create a backend redirection
func (*API) CreateSubscriber ¶
func (s *API) CreateSubscriber(req *CreateSubscriberRequest, opts ...scw.RequestOption) (*Subscriber, error)
CreateSubscriber: create a subscriber, webhook or email
func (*API) DeleteACL ¶
func (s *API) DeleteACL(req *DeleteACLRequest, opts ...scw.RequestOption) error
DeleteACL: delete an ACL
func (*API) DeleteBackend ¶
func (s *API) DeleteBackend(req *DeleteBackendRequest, opts ...scw.RequestOption) error
DeleteBackend: delete a backend in a given load balancer
func (*API) DeleteCertificate ¶
func (s *API) DeleteCertificate(req *DeleteCertificateRequest, opts ...scw.RequestOption) error
DeleteCertificate: delete a TLS certificate
func (*API) DeleteFrontend ¶
func (s *API) DeleteFrontend(req *DeleteFrontendRequest, opts ...scw.RequestOption) error
DeleteFrontend: delete a frontend
func (*API) DeleteLB ¶
func (s *API) DeleteLB(req *DeleteLBRequest, opts ...scw.RequestOption) error
DeleteLB: delete a load balancer
func (*API) DeleteRoute ¶
func (s *API) DeleteRoute(req *DeleteRouteRequest, opts ...scw.RequestOption) error
DeleteRoute: delete a backend redirection
func (*API) DeleteSubscriber ¶
func (s *API) DeleteSubscriber(req *DeleteSubscriberRequest, opts ...scw.RequestOption) error
DeleteSubscriber: delete a subscriber
func (*API) DetachPrivateNetwork ¶
func (s *API) DetachPrivateNetwork(req *DetachPrivateNetworkRequest, opts ...scw.RequestOption) error
DetachPrivateNetwork: remove load balancer of private network
func (*API) GetACL ¶
func (s *API) GetACL(req *GetACLRequest, opts ...scw.RequestOption) (*ACL, error)
GetACL: get an ACL
func (*API) GetBackend ¶
func (s *API) GetBackend(req *GetBackendRequest, opts ...scw.RequestOption) (*Backend, error)
GetBackend: get a backend in a given load balancer
func (*API) GetCertificate ¶
func (s *API) GetCertificate(req *GetCertificateRequest, opts ...scw.RequestOption) (*Certificate, error)
GetCertificate: get a TLS certificate
func (*API) GetFrontend ¶
func (s *API) GetFrontend(req *GetFrontendRequest, opts ...scw.RequestOption) (*Frontend, error)
GetFrontend: get a frontend
func (*API) GetIP ¶
func (s *API) GetIP(req *GetIPRequest, opts ...scw.RequestOption) (*IP, error)
GetIP: get an IP
func (*API) GetLB ¶
func (s *API) GetLB(req *GetLBRequest, opts ...scw.RequestOption) (*LB, error)
GetLB: get a load balancer
func (*API) GetLBStats
deprecated
func (s *API) GetLBStats(req *GetLBStatsRequest, opts ...scw.RequestOption) (*LBStats, error)
Deprecated: GetLBStats: get usage statistics of a given load balancer
func (*API) GetRoute ¶
func (s *API) GetRoute(req *GetRouteRequest, opts ...scw.RequestOption) (*Route, error)
GetRoute: get single backend redirection
func (*API) GetSubscriber ¶
func (s *API) GetSubscriber(req *GetSubscriberRequest, opts ...scw.RequestOption) (*Subscriber, error)
GetSubscriber: get a subscriber
func (*API) ListACLs ¶
func (s *API) ListACLs(req *ListACLsRequest, opts ...scw.RequestOption) (*ListACLResponse, error)
ListACLs: list ACL for a given frontend
func (*API) ListBackendStats ¶
func (s *API) ListBackendStats(req *ListBackendStatsRequest, opts ...scw.RequestOption) (*ListBackendStatsResponse, error)
func (*API) ListBackends ¶
func (s *API) ListBackends(req *ListBackendsRequest, opts ...scw.RequestOption) (*ListBackendsResponse, error)
ListBackends: list backends in a given load balancer
func (*API) ListCertificates ¶
func (s *API) ListCertificates(req *ListCertificatesRequest, opts ...scw.RequestOption) (*ListCertificatesResponse, error)
ListCertificates: list all TLS certificates on a given load balancer
func (*API) ListFrontends ¶
func (s *API) ListFrontends(req *ListFrontendsRequest, opts ...scw.RequestOption) (*ListFrontendsResponse, error)
ListFrontends: list frontends in a given load balancer
func (*API) ListIPs ¶
func (s *API) ListIPs(req *ListIPsRequest, opts ...scw.RequestOption) (*ListIPsResponse, error)
ListIPs: list IPs
func (*API) ListLBPrivateNetworks ¶
func (s *API) ListLBPrivateNetworks(req *ListLBPrivateNetworksRequest, opts ...scw.RequestOption) (*ListLBPrivateNetworksResponse, error)
ListLBPrivateNetworks: list attached private network of load balancer
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)
ListLBs: list load balancers
func (*API) ListRoutes ¶
func (s *API) ListRoutes(req *ListRoutesRequest, opts ...scw.RequestOption) (*ListRoutesResponse, error)
ListRoutes: list all backend redirections
func (*API) ListSubscriber ¶
func (s *API) ListSubscriber(req *ListSubscriberRequest, opts ...scw.RequestOption) (*ListSubscriberResponse, error)
ListSubscriber: list all subscriber
func (*API) MigrateLB ¶
func (s *API) MigrateLB(req *MigrateLBRequest, opts ...scw.RequestOption) (*LB, error)
MigrateLB: migrate a load balancer
func (*API) ReleaseIP ¶
func (s *API) ReleaseIP(req *ReleaseIPRequest, opts ...scw.RequestOption) error
ReleaseIP: delete an IP
func (*API) RemoveBackendServers ¶
func (s *API) RemoveBackendServers(req *RemoveBackendServersRequest, opts ...scw.RequestOption) (*Backend, error)
RemoveBackendServers: remove a set of servers for a given backend
func (*API) SetBackendServers ¶
func (s *API) SetBackendServers(req *SetBackendServersRequest, opts ...scw.RequestOption) (*Backend, error)
SetBackendServers: define all servers in a given backend
func (*API) SubscribeToLB ¶
func (s *API) SubscribeToLB(req *SubscribeToLBRequest, opts ...scw.RequestOption) (*LB, error)
SubscribeToLB: subscribe a subscriber to a given load balancer
func (*API) UnsubscribeFromLB ¶
func (s *API) UnsubscribeFromLB(req *UnsubscribeFromLBRequest, opts ...scw.RequestOption) (*LB, error)
UnsubscribeFromLB: unsubscribe a subscriber from a given load balancer
func (*API) UpdateACL ¶
func (s *API) UpdateACL(req *UpdateACLRequest, opts ...scw.RequestOption) (*ACL, error)
UpdateACL: update an ACL
func (*API) UpdateBackend ¶
func (s *API) UpdateBackend(req *UpdateBackendRequest, opts ...scw.RequestOption) (*Backend, error)
UpdateBackend: update a backend in a given load balancer
func (*API) UpdateCertificate ¶
func (s *API) UpdateCertificate(req *UpdateCertificateRequest, opts ...scw.RequestOption) (*Certificate, error)
UpdateCertificate: update a TLS certificate
func (*API) UpdateFrontend ¶
func (s *API) UpdateFrontend(req *UpdateFrontendRequest, opts ...scw.RequestOption) (*Frontend, error)
UpdateFrontend: update a frontend
func (*API) UpdateHealthCheck ¶
func (s *API) UpdateHealthCheck(req *UpdateHealthCheckRequest, opts ...scw.RequestOption) (*HealthCheck, error)
UpdateHealthCheck: update an health check for a given backend
func (*API) UpdateIP ¶
func (s *API) UpdateIP(req *UpdateIPRequest, opts ...scw.RequestOption) (*IP, error)
UpdateIP: update an IP
func (*API) UpdateLB ¶
func (s *API) UpdateLB(req *UpdateLBRequest, opts ...scw.RequestOption) (*LB, error)
UpdateLB: update a load balancer
func (*API) UpdateRoute ¶
func (s *API) UpdateRoute(req *UpdateRouteRequest, opts ...scw.RequestOption) (*Route, error)
UpdateRoute: edit a backend redirection
func (*API) UpdateSubscriber ¶
func (s *API) UpdateSubscriber(req *UpdateSubscriberRequest, opts ...scw.RequestOption) (*Subscriber, error)
UpdateSubscriber: update a subscriber
func (*API) WaitForLb ¶
func (s *API) WaitForLb(req *WaitForLBRequest, opts ...scw.RequestOption) (*LB, error)
WaitForLb waits for the lb to be in a "terminal state" before returning. This function can be used to wait for a lb to be ready for example.
type AddBackendServersRequest ¶
type AddBackendServersRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// BackendID: backend ID
BackendID string `json:"-"`
// ServerIP: set all IPs to add on your backend
ServerIP []string `json:"server_ip"`
}
type AttachPrivateNetworkRequest ¶
type AttachPrivateNetworkRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// LBID: load balancer ID
LBID string `json:"-"`
// PrivateNetworkID: set your instance private network id
PrivateNetworkID string `json:"-"`
// StaticConfig: define two local ip address of your choice for each load balancer instance
// Precisely one of DHCPConfig, StaticConfig must be set.
StaticConfig *PrivateNetworkStaticConfig `json:"static_config,omitempty"`
// DHCPConfig: set to true if you want to let DHCP assign IP addresses
// Precisely one of DHCPConfig, StaticConfig must be set.
DHCPConfig *PrivateNetworkDHCPConfig `json:"dhcp_config,omitempty"`
}
type Backend ¶
type Backend struct {
// ID: load balancer Backend ID
ID string `json:"id"`
// Name: load balancer Backend name
Name string `json:"name"`
// ForwardProtocol: type of backend protocol
//
// 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 balancer algorithm used to select the backend server
//
// 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 sticky sessions
StickySessionsCookieName string `json:"sticky_sessions_cookie_name"`
// HealthCheck: health Check used to verify backend servers status
HealthCheck *HealthCheck `json:"health_check"`
// Pool: servers IP addresses attached to the backend
Pool []string `json:"pool"`
// LB: load balancer the backend is attached to
LB *LB `json:"lb"`
// Deprecated: SendProxyV2: deprecated in favor of proxy_protocol field
SendProxyV2 *bool `json:"send_proxy_v2,omitempty"`
// TimeoutServer: maximum server connection inactivity time (allowed time the server has to process the request)
TimeoutServer *time.Duration `json:"timeout_server"`
// TimeoutConnect: maximum initial server connection establishment time
TimeoutConnect *time.Duration `json:"timeout_connect"`
// TimeoutTunnel: maximum tunnel inactivity time after Websocket is established (take precedence over client and server timeout)
TimeoutTunnel *time.Duration `json:"timeout_tunnel"`
// OnMarkedDownAction: defines what occurs when a backend server is marked down
//
// Default value: on_marked_down_action_none
OnMarkedDownAction OnMarkedDownAction `json:"on_marked_down_action"`
// ProxyProtocol: pROXY protocol, forward client's address (must be supported by backend servers software)
//
// Default value: proxy_protocol_unknown
ProxyProtocol ProxyProtocol `json:"proxy_protocol"`
// CreatedAt: date at which the backend was created
CreatedAt *time.Time `json:"created_at"`
// UpdatedAt: date at which the backend was updated
UpdatedAt *time.Time `json:"updated_at"`
// FailoverHost: scaleway S3 bucket website to be served in case all backend servers are down
FailoverHost *string `json:"failover_host"`
// SslBridging: enable SSL between load balancer and backend servers
SslBridging *bool `json:"ssl_bridging"`
// IgnoreSslServerVerify: whether or not the server certificate should be verified
IgnoreSslServerVerify *bool `json:"ignore_ssl_server_verify"`
}
Backend: backend
func (Backend) MarshalJSON ¶
func (*Backend) UnmarshalJSON ¶
type BackendServerStats ¶
type BackendServerStats struct {
// InstanceID: ID of your Load balancer 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 health check 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 (Let's encrypt or custom)
//
// 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"`
// CreatedAt: date at which the certificate was created
CreatedAt *time.Time `json:"created_at"`
// UpdatedAt: date at which the certificate was last updated
UpdatedAt *time.Time `json:"updated_at"`
// StatusDetails: additional information on the status (e.g. in case of certificate generation failure)
StatusDetails *string `json:"status_details"`
}
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 CreateACLRequest ¶
type CreateACLRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// FrontendID: ID of your frontend
FrontendID string `json:"-"`
// Name: name of your ACL ressource
Name string `json:"name"`
// Action: action to undertake when an ACL filter matches
Action *ACLAction `json:"action"`
// Match: the ACL match rule
//
// The ACL match rule. You can have one of those three cases:
//
// - `ip_subnet` is defined
// - `http_filter` and `http_filter_value` are defined
// - `ip_subnet`, `http_filter` and `http_filter_value` are defined
//
Match *ACLMatch `json:"match"`
// Index: order between your Acls (ascending order, 0 is first acl executed)
Index int32 `json:"index"`
// Description: description of your ACL ressource
Description string `json:"description"`
}
type CreateBackendRequest ¶
type CreateBackendRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
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 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"`
// Deprecated: SendProxyV2: deprecated in favor of proxy_protocol field !
SendProxyV2 *bool `json:"send_proxy_v2,omitempty"`
// TimeoutServer: maximum server connection inactivity time (allowed time the server has to process the request)
TimeoutServer *time.Duration `json:"timeout_server"`
// TimeoutConnect: maximum initial server connection establishment time
TimeoutConnect *time.Duration `json:"timeout_connect"`
// TimeoutTunnel: maximum tunnel inactivity time after Websocket is established (take precedence over client and server timeout)
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"`
// ProxyProtocol: pROXY protocol, forward client's address (must be supported by backend servers software)
//
// The PROXY protocol informs the other end about the incoming connection, so that it can know the client's address or the public address it accessed to, whatever the upper layer protocol.
//
// * `proxy_protocol_none` Disable proxy protocol.
// * `proxy_protocol_v1` Version one (text format).
// * `proxy_protocol_v2` Version two (binary format).
// * `proxy_protocol_v2_ssl` Version two with SSL connection.
// * `proxy_protocol_v2_ssl_cn` Version two with SSL connection and common name information.
//
// Default value: proxy_protocol_unknown
ProxyProtocol ProxyProtocol `json:"proxy_protocol"`
// FailoverHost: scaleway S3 bucket website to be served in case all backend servers are down
//
// Only the host part of the Scaleway S3 bucket website is expected.
// E.g. `failover-website.s3-website.fr-par.scw.cloud` if your bucket website URL is `https://failover-website.s3-website.fr-par.scw.cloud/`.
//
FailoverHost *string `json:"failover_host"`
// SslBridging: enable SSL between load balancer and backend servers
SslBridging *bool `json:"ssl_bridging"`
// IgnoreSslServerVerify: set to true to ignore server certificate verification
IgnoreSslServerVerify *bool `json:"ignore_ssl_server_verify"`
}
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:
//
// Region to target. If none is passed will use default region from the config
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 CustomCertificate, Letsencrypt must be set.
Letsencrypt *CreateCertificateRequestLetsencryptConfig `json:"letsencrypt,omitempty"`
// CustomCertificate: custom import certificate
// Precisely one of CustomCertificate, Letsencrypt must be set.
CustomCertificate *CreateCertificateRequestCustomCertificate `json:"custom_certificate,omitempty"`
}
type CreateCertificateRequestCustomCertificate ¶
type CreateCertificateRequestCustomCertificate struct {
// CertificateChain: the full PEM-formatted include an entire certificate chain including public key, private key, and optionally certificate authorities.
CertificateChain string `json:"certificate_chain"`
}
CreateCertificateRequestCustomCertificate: import a custom SSL certificate
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:
//
// Region to target. If none is passed will use default region from the config
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"`
// Deprecated: CertificateID: certificate ID, deprecated in favor of certificate_ids array !
CertificateID *string `json:"certificate_id,omitempty"`
// CertificateIDs: list of certificate IDs to bind on the frontend
CertificateIDs *[]string `json:"certificate_ids"`
// EnableHTTP3: activate HTTP 3 protocol (beta)
EnableHTTP3 bool `json:"enable_http3"`
}
func (CreateFrontendRequest) MarshalJSON ¶
func (m CreateFrontendRequest) MarshalJSON() ([]byte, error)
func (*CreateFrontendRequest) UnmarshalJSON ¶
func (m *CreateFrontendRequest) UnmarshalJSON(b []byte) error
type CreateIPRequest ¶
type CreateIPRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// Deprecated: OrganizationID: owner of resources
// Precisely one of OrganizationID, ProjectID must be set.
OrganizationID *string `json:"organization_id,omitempty"`
// ProjectID: assign the resource to a project ID
// Precisely one of OrganizationID, ProjectID must be set.
ProjectID *string `json:"project_id,omitempty"`
// Reverse: reverse domain name
Reverse *string `json:"reverse"`
}
type CreateLBRequest ¶
type CreateLBRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// Deprecated: OrganizationID: owner of resources
// Precisely one of OrganizationID, ProjectID must be set.
OrganizationID *string `json:"organization_id,omitempty"`
// ProjectID: assign the resource to a project ID
// Precisely one of OrganizationID, ProjectID must be set.
ProjectID *string `json:"project_id,omitempty"`
// 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"`
// SslCompatibilityLevel:
//
// Enforces minimal SSL version (in SSL/TLS offloading context).
// - `intermediate` General-purpose servers with a variety of clients, recommended for almost all systems (Supports Firefox 27, Android 4.4.2, Chrome 31, Edge, IE 11 on Windows 7, Java 8u31, OpenSSL 1.0.1, Opera 20, and Safari 9).
// - `modern` Services with clients that support TLS 1.3 and don't need backward compatibility (Firefox 63, Android 10.0, Chrome 70, Edge 75, Java 11, OpenSSL 1.1.1, Opera 57, and Safari 12.1).
// - `old` Compatible with a number of very old clients, and should be used only as a last resort (Firefox 1, Android 2.3, Chrome 1, Edge 12, IE8 on Windows XP, Java 6, OpenSSL 0.9.8, Opera 5, and Safari 1).
//
// Default value: ssl_compatibility_level_unknown
SslCompatibilityLevel SSLCompatibilityLevel `json:"ssl_compatibility_level"`
}
type CreateRouteRequest ¶
type CreateRouteRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// FrontendID: origin of redirection
FrontendID string `json:"frontend_id"`
// BackendID: destination of destination
BackendID string `json:"backend_id"`
// Match: value to match a redirection
Match *RouteMatch `json:"match"`
}
type CreateSubscriberRequest ¶
type CreateSubscriberRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// Name: subscriber name
Name string `json:"name"`
// EmailConfig: email address configuration
// Precisely one of EmailConfig, WebhookConfig must be set.
EmailConfig *SubscriberEmailConfig `json:"email_config,omitempty"`
// WebhookConfig: webHook URI configuration
// Precisely one of EmailConfig, WebhookConfig must be set.
WebhookConfig *SubscriberWebhookConfig `json:"webhook_config,omitempty"`
// Deprecated: OrganizationID: owner of resources
// Precisely one of OrganizationID, ProjectID must be set.
OrganizationID *string `json:"organization_id,omitempty"`
// ProjectID: assign the resource to a project ID
// Precisely one of OrganizationID, ProjectID must be set.
ProjectID *string `json:"project_id,omitempty"`
}
type DeleteACLRequest ¶
type DeleteBackendRequest ¶
type DeleteFrontendRequest ¶
type DeleteLBRequest ¶
type DeleteRouteRequest ¶
type DeleteSubscriberRequest ¶
type DetachPrivateNetworkRequest ¶
type DetachPrivateNetworkRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// LBID: load balancer ID
LBID string `json:"-"`
// PrivateNetworkID: set your instance private network id
PrivateNetworkID string `json:"-"`
}
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: load balancer Frontend ID
ID string `json:"id"`
// Name: load balancer Frontend name
Name string `json:"name"`
// InboundPort: TCP port to listen on the front side
InboundPort int32 `json:"inbound_port"`
// Backend: backend resource the Frontend is attached to
Backend *Backend `json:"backend"`
// LB: load balancer the frontend is attached to
LB *LB `json:"lb"`
// TimeoutClient: maximum inactivity time on the client side
TimeoutClient *time.Duration `json:"timeout_client"`
// Deprecated: Certificate: certificate, deprecated in favor of certificate_ids array
Certificate *Certificate `json:"certificate,omitempty"`
// CertificateIDs: list of certificate IDs to bind on the frontend
CertificateIDs []string `json:"certificate_ids"`
// CreatedAt: date at which the frontend was created
CreatedAt *time.Time `json:"created_at"`
// UpdatedAt: date at which the frontend was updated
UpdatedAt *time.Time `json:"updated_at"`
// EnableHTTP3: whether or not HTTP3 protocol is enabled
EnableHTTP3 bool `json:"enable_http3"`
}
Frontend: frontend
func (Frontend) MarshalJSON ¶
func (*Frontend) UnmarshalJSON ¶
type GetACLRequest ¶
type GetBackendRequest ¶
type GetCertificateRequest ¶
type GetFrontendRequest ¶
type GetIPRequest ¶
type GetLBRequest ¶
type GetLBStatsRequest ¶
type GetRouteRequest ¶
type GetSubscriberRequest ¶
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: number of consecutive unsuccessful health checks, after which the server will be considered dead
CheckMaxRetries int32 `json:"check_max_retries"`
// TCPConfig: basic TCP health check
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
TCPConfig *HealthCheckTCPConfig `json:"tcp_config,omitempty"`
// PgsqlConfig: postgreSQL health check
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
PgsqlConfig *HealthCheckPgsqlConfig `json:"pgsql_config,omitempty"`
// HTTPConfig: HTTP health check
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
HTTPConfig *HealthCheckHTTPConfig `json:"http_config,omitempty"`
// HTTPSConfig: HTTPS health check
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
HTTPSConfig *HealthCheckHTTPSConfig `json:"https_config,omitempty"`
// Port: TCP port to use for the backend server health check
Port int32 `json:"port"`
// CheckTimeout: maximum time a backend server has to reply to the health check
CheckTimeout *time.Duration `json:"check_timeout"`
// CheckDelay: time between two consecutive health checks
CheckDelay *time.Duration `json:"check_delay"`
// CheckSendProxy: it defines whether the health check should be done considering the proxy protocol
CheckSendProxy bool `json:"check_send_proxy"`
}
HealthCheck: health check
func (HealthCheck) MarshalJSON ¶
func (m HealthCheck) MarshalJSON() ([]byte, error)
func (*HealthCheck) UnmarshalJSON ¶
func (m *HealthCheck) UnmarshalJSON(b []byte) error
type HealthCheckHTTPConfig ¶
type HealthCheckHTTPConfig struct {
// URI: HTTP uri used with the request
//
// HTTP uri used for Healthcheck to the backend servers
URI string `json:"uri"`
// Method: HTTP method used with the request
//
// HTTP method used for Healthcheck to the backend servers
Method string `json:"method"`
// Code: HTTP response code so the Healthcheck is considered successfull
//
// A health check response will be considered as valid if the response's status code match
Code *int32 `json:"code"`
// HostHeader: HTTP host header used with the request
HostHeader string `json:"host_header"`
}
HealthCheckHTTPConfig: health check. http config
type HealthCheckHTTPSConfig ¶
type HealthCheckHTTPSConfig struct {
// URI: HTTP uri used with the request
//
// HTTP uri used for Healthcheck to the backend servers
URI string `json:"uri"`
// Method: HTTP method used with the request
//
// HTTP method used for Healthcheck to the backend servers
Method string `json:"method"`
// Code: HTTP response code so the Healthcheck is considered successfull
//
// A health check response will be considered as valid if the response's status code match
Code *int32 `json:"code"`
// HostHeader: HTTP host header used with the request
HostHeader string `json:"host_header"`
// Sni: specifies the SNI to use to do health checks over SSL
//
// Specifies the SNI to use to do health checks over SSL
Sni string `json:"sni"`
}
HealthCheckHTTPSConfig: health check. https config
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 IP ¶
type IP struct {
// ID: flexible IP ID
ID string `json:"id"`
// IPAddress: IP address
IPAddress string `json:"ip_address"`
// OrganizationID: organization ID
OrganizationID string `json:"organization_id"`
// ProjectID: project ID
ProjectID string `json:"project_id"`
// LBID: load balancer ID
LBID *string `json:"lb_id"`
// Reverse: reverse FQDN
Reverse string `json:"reverse"`
// Deprecated: Region: the region the Flexible IP is in
Region *scw.Region `json:"region,omitempty"`
// Zone: the zone the Flexible IP is in
Zone scw.Zone `json:"zone"`
}
IP: ip
type Instance ¶
type Instance struct {
// ID: underlying Instance ID
ID string `json:"id"`
// Status: instance status
//
// Default value: unknown
Status InstanceStatus `json:"status"`
// IPAddress: instance IP address
IPAddress string `json:"ip_address"`
// CreatedAt: date at which the Instance was created
CreatedAt *time.Time `json:"created_at"`
// UpdatedAt: date at which the Instance was updated
UpdatedAt *time.Time `json:"updated_at"`
// Deprecated: Region: the region the instance is in
Region *scw.Region `json:"region,omitempty"`
// Zone: the zone the instance is in
Zone scw.Zone `json:"zone"`
}
Instance: instance
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: underlying Instance ID
ID string `json:"id"`
// Name: load balancer name
Name string `json:"name"`
// Description: load balancer description
Description string `json:"description"`
// Status: load balancer status
//
// Default value: unknown
Status LBStatus `json:"status"`
// Instances: list of underlying instances
Instances []*Instance `json:"instances"`
// OrganizationID: organization ID
OrganizationID string `json:"organization_id"`
// ProjectID: project ID
ProjectID string `json:"project_id"`
// IP: list of IPs attached to the Load balancer
IP []*IP `json:"ip"`
// Tags: load balancer tags
Tags []string `json:"tags"`
// FrontendCount: number of frontends the Load balancer has
FrontendCount int32 `json:"frontend_count"`
// BackendCount: number of backends the Load balancer has
BackendCount int32 `json:"backend_count"`
// Type: load balancer offer type
Type string `json:"type"`
// Subscriber: subscriber information
Subscriber *Subscriber `json:"subscriber"`
// SslCompatibilityLevel: determines the minimal SSL version which needs to be supported on client side
//
// Default value: ssl_compatibility_level_unknown
SslCompatibilityLevel SSLCompatibilityLevel `json:"ssl_compatibility_level"`
// CreatedAt: date at which the Load balancer was created
CreatedAt *time.Time `json:"created_at"`
// UpdatedAt: date at which the Load balancer was updated
UpdatedAt *time.Time `json:"updated_at"`
// PrivateNetworkCount: number of private networks attached to the Load balancer
PrivateNetworkCount int32 `json:"private_network_count"`
// RouteCount: number of routes the Load balancer has
RouteCount int32 `json:"route_count"`
// Deprecated: Region: the region the Load balancer is in
Region *scw.Region `json:"region,omitempty"`
// Zone: the zone the Load balancer is in
Zone scw.Zone `json:"zone"`
}
LB: lb
type LBStats ¶
type LBStats struct {
// BackendServersStats: list stats object of your Load balancer
BackendServersStats []*BackendServerStats `json:"backend_servers_stats"`
}
LBStats: lb stats
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: the total number of items
TotalCount uint32 `json:"total_count"`
}
ListACLResponse: list acl response
func (*ListACLResponse) UnsafeAppend ¶
func (r *ListACLResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListACLResponse) UnsafeGetTotalCount ¶
func (r *ListACLResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type ListACLsRequest ¶
type ListACLsRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// FrontendID: ID of your frontend
FrontendID string `json:"-"`
// OrderBy: response order
//
// Default value: created_at_asc
OrderBy ListACLRequestOrderBy `json:"-"`
// Page: page number
Page *int32 `json:"-"`
// PageSize: the number of items to return
PageSize *uint32 `json:"-"`
// Name: filter acl per name
Name *string `json:"-"`
}
type ListBackendStatsRequest ¶
type ListBackendStatsRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// LBID: load balancer ID
LBID string `json:"-"`
// Page: page number
Page *int32 `json:"-"`
// PageSize: the number of items to return
PageSize *uint32 `json:"-"`
}
type ListBackendStatsResponse ¶
type ListBackendStatsResponse struct {
// BackendServersStats: list backend stats object of your Load balancer
BackendServersStats []*BackendServerStats `json:"backend_servers_stats"`
// TotalCount: the total number of items
TotalCount uint32 `json:"total_count"`
}
ListBackendStatsResponse: list backend stats response
func (*ListBackendStatsResponse) UnsafeAppend ¶
func (r *ListBackendStatsResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListBackendStatsResponse) UnsafeGetTotalCount ¶
func (r *ListBackendStatsResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type ListBackendsRequest ¶
type ListBackendsRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
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 ListBackendsRequestOrderBy `json:"-"`
// Page: page number
Page *int32 `json:"-"`
// PageSize: the number of items to return
PageSize *uint32 `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"`
}
ListBackendsResponse: list backends response
func (*ListBackendsResponse) UnsafeAppend ¶
func (r *ListBackendsResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListBackendsResponse) UnsafeGetTotalCount ¶
func (r *ListBackendsResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type ListCertificatesRequest ¶
type ListCertificatesRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// LBID: load balancer ID
LBID string `json:"-"`
// OrderBy: response order
//
// Default value: created_at_asc
OrderBy ListCertificatesRequestOrderBy `json:"-"`
// Page: page number
Page *int32 `json:"-"`
// PageSize: the number of items to return
PageSize *uint32 `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: list of certificates
Certificates []*Certificate `json:"certificates"`
// TotalCount: the total number of items
TotalCount uint32 `json:"total_count"`
}
ListCertificatesResponse: list certificates response
func (*ListCertificatesResponse) UnsafeAppend ¶
func (r *ListCertificatesResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListCertificatesResponse) UnsafeGetTotalCount ¶
func (r *ListCertificatesResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type ListFrontendsRequest ¶
type ListFrontendsRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
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: the number of items to return
PageSize *uint32 `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 Load balancer
Frontends []*Frontend `json:"frontends"`
// TotalCount: total count, wihtout pagination
TotalCount uint32 `json:"total_count"`
}
ListFrontendsResponse: list frontends response
func (*ListFrontendsResponse) UnsafeAppend ¶
func (r *ListFrontendsResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListFrontendsResponse) UnsafeGetTotalCount ¶
func (r *ListFrontendsResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type ListIPsRequest ¶
type ListIPsRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// Page: page number
Page *int32 `json:"-"`
// PageSize: the number of items to return
PageSize *uint32 `json:"-"`
// IPAddress: use this to search by IP address
IPAddress *string `json:"-"`
// OrganizationID: filter IPs by organization id
OrganizationID *string `json:"-"`
// ProjectID: filter IPs by project ID
ProjectID *string `json:"-"`
}
type ListIPsResponse ¶
type ListIPsResponse struct {
// IPs: list IP address object
IPs []*IP `json:"ips"`
// TotalCount: total count, wihtout pagination
TotalCount uint32 `json:"total_count"`
}
ListIPsResponse: list ips response
func (*ListIPsResponse) UnsafeAppend ¶
func (r *ListIPsResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListIPsResponse) UnsafeGetTotalCount ¶
func (r *ListIPsResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type ListLBPrivateNetworksRequest ¶
type ListLBPrivateNetworksRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// LBID: load balancer ID
LBID string `json:"-"`
// OrderBy: response order
//
// Default value: created_at_asc
OrderBy ListPrivateNetworksRequestOrderBy `json:"-"`
// PageSize: the number of items to return
PageSize *uint32 `json:"-"`
// Page: page number
Page *int32 `json:"-"`
}
type ListLBPrivateNetworksResponse ¶
type ListLBPrivateNetworksResponse struct {
// PrivateNetwork: private networks of a given load balancer
PrivateNetwork []*PrivateNetwork `json:"private_network"`
// TotalCount: the total number of items
TotalCount uint32 `json:"total_count"`
}
ListLBPrivateNetworksResponse: list lb private networks response
func (*ListLBPrivateNetworksResponse) UnsafeAppend ¶
func (r *ListLBPrivateNetworksResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListLBPrivateNetworksResponse) UnsafeGetTotalCount ¶
func (r *ListLBPrivateNetworksResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type ListLBTypesRequest ¶
type ListLBTypesResponse ¶
type ListLBTypesResponse struct {
// LBTypes: different types of LB
LBTypes []*LBType `json:"lb_types"`
// TotalCount: the total number of items
TotalCount uint32 `json:"total_count"`
}
ListLBTypesResponse: list lb types response
func (*ListLBTypesResponse) UnsafeAppend ¶
func (r *ListLBTypesResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListLBTypesResponse) UnsafeGetTotalCount ¶
func (r *ListLBTypesResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type ListLBsRequest ¶
type ListLBsRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// Name: use this to search by name
Name *string `json:"-"`
// OrderBy: response order
//
// Default value: created_at_asc
OrderBy ListLBsRequestOrderBy `json:"-"`
// PageSize: the number of items to return
PageSize *uint32 `json:"-"`
// Page: page number
Page *int32 `json:"-"`
// OrganizationID: filter LBs by organization ID
OrganizationID *string `json:"-"`
// ProjectID: filter LBs by project ID
ProjectID *string `json:"-"`
}
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 ¶
type ListLBsResponse struct {
// LBs: list of Load balancer
LBs []*LB `json:"lbs"`
// TotalCount: the total number of items
TotalCount uint32 `json:"total_count"`
}
ListLBsResponse: get list of Load balancers
func (*ListLBsResponse) UnsafeAppend ¶
func (r *ListLBsResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListLBsResponse) UnsafeGetTotalCount ¶
func (r *ListLBsResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type ListPrivateNetworksRequestOrderBy ¶
type ListPrivateNetworksRequestOrderBy string
func (ListPrivateNetworksRequestOrderBy) MarshalJSON ¶
func (enum ListPrivateNetworksRequestOrderBy) MarshalJSON() ([]byte, error)
func (ListPrivateNetworksRequestOrderBy) String ¶
func (enum ListPrivateNetworksRequestOrderBy) String() string
func (*ListPrivateNetworksRequestOrderBy) UnmarshalJSON ¶
func (enum *ListPrivateNetworksRequestOrderBy) UnmarshalJSON(data []byte) error
type ListRoutesRequest ¶
type ListRoutesRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// OrderBy: response order
//
// Default value: created_at_asc
OrderBy ListRoutesRequestOrderBy `json:"-"`
// PageSize: the number of items to return
PageSize *uint32 `json:"-"`
// Page: page number
Page *int32 `json:"-"`
FrontendID *string `json:"-"`
}
type ListRoutesRequestOrderBy ¶
type ListRoutesRequestOrderBy string
func (ListRoutesRequestOrderBy) MarshalJSON ¶
func (enum ListRoutesRequestOrderBy) MarshalJSON() ([]byte, error)
func (ListRoutesRequestOrderBy) String ¶
func (enum ListRoutesRequestOrderBy) String() string
func (*ListRoutesRequestOrderBy) UnmarshalJSON ¶
func (enum *ListRoutesRequestOrderBy) UnmarshalJSON(data []byte) error
type ListRoutesResponse ¶
type ListRoutesResponse struct {
// Routes: list of Routes object
Routes []*Route `json:"routes"`
// TotalCount: the total number of items
TotalCount uint32 `json:"total_count"`
}
ListRoutesResponse: list routes response
func (*ListRoutesResponse) UnsafeAppend ¶
func (r *ListRoutesResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListRoutesResponse) UnsafeGetTotalCount ¶
func (r *ListRoutesResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type ListSubscriberRequest ¶
type ListSubscriberRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// OrderBy: response order
//
// Default value: created_at_asc
OrderBy ListSubscriberRequestOrderBy `json:"-"`
// Page: page number
Page *int32 `json:"-"`
// PageSize: the number of items to return
PageSize *uint32 `json:"-"`
// Name: use this to search by name
Name *string `json:"-"`
// OrganizationID: filter Subscribers by organization ID
OrganizationID *string `json:"-"`
// ProjectID: filter Subscribers by project ID
ProjectID *string `json:"-"`
}
type ListSubscriberRequestOrderBy ¶
type ListSubscriberRequestOrderBy string
func (ListSubscriberRequestOrderBy) MarshalJSON ¶
func (enum ListSubscriberRequestOrderBy) MarshalJSON() ([]byte, error)
func (ListSubscriberRequestOrderBy) String ¶
func (enum ListSubscriberRequestOrderBy) String() string
func (*ListSubscriberRequestOrderBy) UnmarshalJSON ¶
func (enum *ListSubscriberRequestOrderBy) UnmarshalJSON(data []byte) error
type ListSubscriberResponse ¶
type ListSubscriberResponse struct {
// Subscribers: list of Subscribers object
Subscribers []*Subscriber `json:"subscribers"`
// TotalCount: the total number of items
TotalCount uint32 `json:"total_count"`
}
ListSubscriberResponse: list subscriber response
func (*ListSubscriberResponse) UnsafeAppend ¶
func (r *ListSubscriberResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListSubscriberResponse) UnsafeGetTotalCount ¶
func (r *ListSubscriberResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type MigrateLBRequest ¶
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 PrivateNetwork ¶
type PrivateNetwork struct {
// LB: loadBalancer object
LB *LB `json:"lb"`
// StaticConfig: local ip address of load balancer instance
// Precisely one of DHCPConfig, StaticConfig must be set.
StaticConfig *PrivateNetworkStaticConfig `json:"static_config,omitempty"`
// DHCPConfig: value set to true if load balancer instance use a DHCP
// Precisely one of DHCPConfig, StaticConfig must be set.
DHCPConfig *PrivateNetworkDHCPConfig `json:"dhcp_config,omitempty"`
// PrivateNetworkID: instance private network id
PrivateNetworkID string `json:"private_network_id"`
// Status: status (running, to create...) of private network connection
//
// Default value: unknown
Status PrivateNetworkStatus `json:"status"`
// CreatedAt: date at which the PN was created
CreatedAt *time.Time `json:"created_at"`
// UpdatedAt: date at which the PN was last updated
UpdatedAt *time.Time `json:"updated_at"`
}
PrivateNetwork: private network
type PrivateNetworkDHCPConfig ¶
type PrivateNetworkDHCPConfig struct {
}
type PrivateNetworkStaticConfig ¶
type PrivateNetworkStaticConfig struct {
IPAddress []string `json:"ip_address"`
}
type PrivateNetworkStatus ¶
type PrivateNetworkStatus string
func (PrivateNetworkStatus) MarshalJSON ¶
func (enum PrivateNetworkStatus) MarshalJSON() ([]byte, error)
func (PrivateNetworkStatus) String ¶
func (enum PrivateNetworkStatus) String() string
func (*PrivateNetworkStatus) UnmarshalJSON ¶
func (enum *PrivateNetworkStatus) UnmarshalJSON(data []byte) error
type ProxyProtocol ¶
type ProxyProtocol string
ProxyProtocol: pROXY protocol, forward client's address (must be supported by backend servers software)
The PROXY protocol informs the other end about the incoming connection, so that it can know the client's address or the public address it accessed to, whatever the upper layer protocol.
* `proxy_protocol_none` Disable proxy protocol. * `proxy_protocol_v1` Version one (text format). * `proxy_protocol_v2` Version two (binary format). * `proxy_protocol_v2_ssl` Version two with SSL connection. * `proxy_protocol_v2_ssl_cn` Version two with SSL connection and common name information.
func (ProxyProtocol) MarshalJSON ¶
func (enum ProxyProtocol) MarshalJSON() ([]byte, error)
func (ProxyProtocol) String ¶
func (enum ProxyProtocol) String() string
func (*ProxyProtocol) UnmarshalJSON ¶
func (enum *ProxyProtocol) UnmarshalJSON(data []byte) error
type ReleaseIPRequest ¶
type RemoveBackendServersRequest ¶
type RemoveBackendServersRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// BackendID: backend ID
BackendID string `json:"-"`
// ServerIP: set all IPs to remove of your backend
ServerIP []string `json:"server_ip"`
}
type Route ¶
type Route struct {
// ID: id of match ressource
ID string `json:"id"`
// FrontendID: id of frontend
FrontendID string `json:"frontend_id"`
// BackendID: id of backend
BackendID string `json:"backend_id"`
// Match: value to match a redirection
Match *RouteMatch `json:"match"`
// CreatedAt: date at which the route was created
CreatedAt *time.Time `json:"created_at"`
// UpdatedAt: date at which the route was last updated
UpdatedAt *time.Time `json:"updated_at"`
}
Route: route
type RouteMatch ¶
type RouteMatch struct {
// Sni: server Name Indication TLS extension (SNI)
//
// Server Name Indication TLS extension (SNI) field from an incoming connection made via an SSL/TLS transport layer
// Precisely one of HostHeader, Sni must be set.
Sni *string `json:"sni,omitempty"`
// HostHeader: HTTP host header to match
//
// The Host request header specifies the host of the server to which the request is being sent
// Precisely one of HostHeader, Sni must be set.
HostHeader *string `json:"host_header,omitempty"`
}
RouteMatch: route. match
type SSLCompatibilityLevel ¶
type SSLCompatibilityLevel string
func (SSLCompatibilityLevel) MarshalJSON ¶
func (enum SSLCompatibilityLevel) MarshalJSON() ([]byte, error)
func (SSLCompatibilityLevel) String ¶
func (enum SSLCompatibilityLevel) String() string
func (*SSLCompatibilityLevel) UnmarshalJSON ¶
func (enum *SSLCompatibilityLevel) UnmarshalJSON(data []byte) error
type SetACLsResponse ¶
type SetACLsResponse struct {
// ACLs: list of ACLs object (see ACL object description)
ACLs []*ACL `json:"acls"`
// TotalCount: the total number of items
TotalCount uint32 `json:"total_count"`
}
SetACLsResponse: set acls response
type SetBackendServersRequest ¶
type SetBackendServersRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// BackendID: backend ID
BackendID string `json:"-"`
// ServerIP: set all IPs to add on your backend and remove all other
ServerIP []string `json:"server_ip"`
}
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 SubscribeToLBRequest ¶
type Subscriber ¶
type Subscriber struct {
// ID: subscriber ID
ID string `json:"id"`
// Name: subscriber name
Name string `json:"name"`
// EmailConfig: email address of subscriber
// Precisely one of EmailConfig, WebhookConfig must be set.
EmailConfig *SubscriberEmailConfig `json:"email_config,omitempty"`
// WebhookConfig: webHook URI of subscriber
// Precisely one of EmailConfig, WebhookConfig must be set.
WebhookConfig *SubscriberWebhookConfig `json:"webhook_config,omitempty"`
}
Subscriber: subscriber
type SubscriberEmailConfig ¶
type SubscriberEmailConfig struct {
// Email: email who receive alert
Email string `json:"email"`
}
SubscriberEmailConfig: email alert of subscriber
type SubscriberWebhookConfig ¶
type SubscriberWebhookConfig struct {
// URI: URI who receive POST request
URI string `json:"uri"`
}
SubscriberWebhookConfig: webhook alert of subscriber
type UpdateACLRequest ¶
type UpdateACLRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// ACLID: ID of your ACL ressource
ACLID string `json:"-"`
// Name: name of your ACL ressource
Name string `json:"name"`
// Action: action to undertake when an ACL filter matches
Action *ACLAction `json:"action"`
// Match: the ACL match rule. At least `ip_subnet` or `http_filter` and `http_filter_value` are required
Match *ACLMatch `json:"match"`
// Index: order between your Acls (ascending order, 0 is first acl executed)
Index int32 `json:"index"`
// Description: description of your ACL ressource
Description *string `json:"description"`
}
type UpdateBackendRequest ¶
type UpdateBackendRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
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 sticky sessions
StickySessionsCookieName string `json:"sticky_sessions_cookie_name"`
// Deprecated: SendProxyV2: deprecated in favor of proxy_protocol field!
SendProxyV2 *bool `json:"send_proxy_v2,omitempty"`
// TimeoutServer: maximum server connection inactivity time (allowed time the server has to process the request)
TimeoutServer *time.Duration `json:"timeout_server"`
// TimeoutConnect: maximum initial server connection establishment time
TimeoutConnect *time.Duration `json:"timeout_connect"`
// TimeoutTunnel: maximum tunnel inactivity time after Websocket is established (take precedence over client and server timeout)
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"`
// ProxyProtocol: pROXY protocol, forward client's address (must be supported by backend servers software)
//
// The PROXY protocol informs the other end about the incoming connection, so that it can know the client's address or the public address it accessed to, whatever the upper layer protocol is.
//
// * `proxy_protocol_none` Disable proxy protocol.
// * `proxy_protocol_v1` Version one (text format).
// * `proxy_protocol_v2` Version two (binary format).
// * `proxy_protocol_v2_ssl` Version two with SSL connection.
// * `proxy_protocol_v2_ssl_cn` Version two with SSL connection and common name information.
//
// Default value: proxy_protocol_unknown
ProxyProtocol ProxyProtocol `json:"proxy_protocol"`
// FailoverHost: scaleway S3 bucket website to be served in case all backend servers are down
//
// Only the host part of the Scaleway S3 bucket website is expected.
// Example: `failover-website.s3-website.fr-par.scw.cloud` if your bucket website URL is `https://failover-website.s3-website.fr-par.scw.cloud/`.
//
FailoverHost *string `json:"failover_host"`
// SslBridging: enable SSL between load balancer and backend servers
SslBridging *bool `json:"ssl_bridging"`
// IgnoreSslServerVerify: set to true to ignore server certificate verification
IgnoreSslServerVerify *bool `json:"ignore_ssl_server_verify"`
}
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:
//
// Region to target. If none is passed will use default region from the config
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"`
// Deprecated: CertificateID: certificate ID, deprecated in favor of `certificate_ids` array!
CertificateID *string `json:"certificate_id,omitempty"`
// CertificateIDs: list of certificate IDs to bind on the frontend
CertificateIDs *[]string `json:"certificate_ids"`
// EnableHTTP3: activate HTTP 3 protocol (beta)
EnableHTTP3 bool `json:"enable_http3"`
}
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:
//
// Region to target. If none is passed will use default region from the config
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: maximum time a backend server has to reply to the health check
CheckTimeout *time.Duration `json:"check_timeout"`
// CheckMaxRetries: number of consecutive unsuccessful health checks, after which 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"`
// PgsqlConfig: postgreSQL health check
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
PgsqlConfig *HealthCheckPgsqlConfig `json:"pgsql_config,omitempty"`
// TCPConfig: basic TCP health check
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
TCPConfig *HealthCheckTCPConfig `json:"tcp_config,omitempty"`
// HTTPConfig: HTTP health check
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
HTTPConfig *HealthCheckHTTPConfig `json:"http_config,omitempty"`
// HTTPSConfig: HTTPS health check
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
HTTPSConfig *HealthCheckHTTPSConfig `json:"https_config,omitempty"`
// CheckSendProxy: it defines whether the health check should be done considering the proxy protocol
CheckSendProxy bool `json:"check_send_proxy"`
}
func (UpdateHealthCheckRequest) MarshalJSON ¶
func (m UpdateHealthCheckRequest) MarshalJSON() ([]byte, error)
func (*UpdateHealthCheckRequest) UnmarshalJSON ¶
func (m *UpdateHealthCheckRequest) UnmarshalJSON(b []byte) error
type UpdateIPRequest ¶
type UpdateLBRequest ¶
type UpdateLBRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// LBID: load balancer ID
LBID string `json:"-"`
// Name: resource name
Name string `json:"name"`
// Description: resource description
Description string `json:"description"`
// Tags: list of keywords
Tags []string `json:"tags"`
// SslCompatibilityLevel:
//
// Enforces minimal SSL version (in SSL/TLS offloading context).
// - `intermediate` General-purpose servers with a variety of clients, recommended for almost all systems (Supports Firefox 27, Android 4.4.2, Chrome 31, Edge, IE 11 on Windows 7, Java 8u31, OpenSSL 1.0.1, Opera 20, and Safari 9).
// - `modern` Services with clients that support TLS 1.3 and don't need backward compatibility (Firefox 63, Android 10.0, Chrome 70, Edge 75, Java 11, OpenSSL 1.1.1, Opera 57, and Safari 12.1).
// - `old` Compatible with a number of very old clients, and should be used only as a last resort (Firefox 1, Android 2.3, Chrome 1, Edge 12, IE8 on Windows XP, Java 6, OpenSSL 0.9.8, Opera 5, and Safari 1).
//
// Default value: ssl_compatibility_level_unknown
SslCompatibilityLevel SSLCompatibilityLevel `json:"ssl_compatibility_level"`
}
type UpdateRouteRequest ¶
type UpdateRouteRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// RouteID: route id to update
RouteID string `json:"-"`
// BackendID: backend id of redirection
BackendID string `json:"backend_id"`
// Match: value to match a redirection
Match *RouteMatch `json:"match"`
}
type UpdateSubscriberRequest ¶
type UpdateSubscriberRequest struct {
// Region:
//
// Region to target. If none is passed will use default region from the config
Region scw.Region `json:"-"`
// SubscriberID: assign the resource to a project IDs
SubscriberID string `json:"-"`
// Name: subscriber name
Name string `json:"name"`
// EmailConfig: email address configuration
// Precisely one of EmailConfig, WebhookConfig must be set.
EmailConfig *SubscriberEmailConfig `json:"email_config,omitempty"`
// WebhookConfig: webHook URI configuration
// Precisely one of EmailConfig, WebhookConfig must be set.
WebhookConfig *SubscriberWebhookConfig `json:"webhook_config,omitempty"`
}
type WaitForLBRequest ¶
type WaitForLBRequest struct {
LBID string
Region scw.Region
Timeout *time.Duration
RetryInterval *time.Duration
}
WaitForLBRequest is used by WaitForLb method.
type ZonedAPI ¶
type ZonedAPI struct {
// contains filtered or unexported fields
}
ZonedAPI: this API allows you to manage your load balancer service
func NewZonedAPI ¶
NewZonedAPI returns a ZonedAPI object from a Scaleway client.
func (*ZonedAPI) AddBackendServers ¶
func (s *ZonedAPI) AddBackendServers(req *ZonedAPIAddBackendServersRequest, opts ...scw.RequestOption) (*Backend, error)
AddBackendServers: add a set of servers in a given backend
func (*ZonedAPI) AttachPrivateNetwork ¶
func (s *ZonedAPI) AttachPrivateNetwork(req *ZonedAPIAttachPrivateNetworkRequest, opts ...scw.RequestOption) (*PrivateNetwork, error)
AttachPrivateNetwork: add load balancer on instance private network
func (*ZonedAPI) CreateACL ¶
func (s *ZonedAPI) CreateACL(req *ZonedAPICreateACLRequest, opts ...scw.RequestOption) (*ACL, error)
CreateACL: create an ACL for a given frontend
func (*ZonedAPI) CreateBackend ¶
func (s *ZonedAPI) CreateBackend(req *ZonedAPICreateBackendRequest, opts ...scw.RequestOption) (*Backend, error)
CreateBackend: create a backend in a given load balancer
func (*ZonedAPI) CreateCertificate ¶
func (s *ZonedAPI) CreateCertificate(req *ZonedAPICreateCertificateRequest, opts ...scw.RequestOption) (*Certificate, error)
CreateCertificate: create a TLS certificate
Generate a new TLS certificate using Let's Encrypt or import your certificate.
func (*ZonedAPI) CreateFrontend ¶
func (s *ZonedAPI) CreateFrontend(req *ZonedAPICreateFrontendRequest, opts ...scw.RequestOption) (*Frontend, error)
CreateFrontend: create a frontend in a given load balancer
func (*ZonedAPI) CreateIP ¶
func (s *ZonedAPI) CreateIP(req *ZonedAPICreateIPRequest, opts ...scw.RequestOption) (*IP, error)
CreateIP: create an IP
func (*ZonedAPI) CreateLB ¶
func (s *ZonedAPI) CreateLB(req *ZonedAPICreateLBRequest, opts ...scw.RequestOption) (*LB, error)
CreateLB: create a load balancer
func (*ZonedAPI) CreateRoute ¶
func (s *ZonedAPI) CreateRoute(req *ZonedAPICreateRouteRequest, opts ...scw.RequestOption) (*Route, error)
CreateRoute: create a backend redirection
func (*ZonedAPI) CreateSubscriber ¶
func (s *ZonedAPI) CreateSubscriber(req *ZonedAPICreateSubscriberRequest, opts ...scw.RequestOption) (*Subscriber, error)
CreateSubscriber: create a subscriber, webhook or email
func (*ZonedAPI) DeleteACL ¶
func (s *ZonedAPI) DeleteACL(req *ZonedAPIDeleteACLRequest, opts ...scw.RequestOption) error
DeleteACL: delete an ACL
func (*ZonedAPI) DeleteBackend ¶
func (s *ZonedAPI) DeleteBackend(req *ZonedAPIDeleteBackendRequest, opts ...scw.RequestOption) error
DeleteBackend: delete a backend in a given load balancer
func (*ZonedAPI) DeleteCertificate ¶
func (s *ZonedAPI) DeleteCertificate(req *ZonedAPIDeleteCertificateRequest, opts ...scw.RequestOption) error
DeleteCertificate: delete a TLS certificate
func (*ZonedAPI) DeleteFrontend ¶
func (s *ZonedAPI) DeleteFrontend(req *ZonedAPIDeleteFrontendRequest, opts ...scw.RequestOption) error
DeleteFrontend: delete a frontend
func (*ZonedAPI) DeleteLB ¶
func (s *ZonedAPI) DeleteLB(req *ZonedAPIDeleteLBRequest, opts ...scw.RequestOption) error
DeleteLB: delete a load balancer
func (*ZonedAPI) DeleteRoute ¶
func (s *ZonedAPI) DeleteRoute(req *ZonedAPIDeleteRouteRequest, opts ...scw.RequestOption) error
DeleteRoute: delete a backend redirection
func (*ZonedAPI) DeleteSubscriber ¶
func (s *ZonedAPI) DeleteSubscriber(req *ZonedAPIDeleteSubscriberRequest, opts ...scw.RequestOption) error
DeleteSubscriber: delete a subscriber
func (*ZonedAPI) DetachPrivateNetwork ¶
func (s *ZonedAPI) DetachPrivateNetwork(req *ZonedAPIDetachPrivateNetworkRequest, opts ...scw.RequestOption) error
DetachPrivateNetwork: remove load balancer of private network
func (*ZonedAPI) GetACL ¶
func (s *ZonedAPI) GetACL(req *ZonedAPIGetACLRequest, opts ...scw.RequestOption) (*ACL, error)
GetACL: get an ACL
func (*ZonedAPI) GetBackend ¶
func (s *ZonedAPI) GetBackend(req *ZonedAPIGetBackendRequest, opts ...scw.RequestOption) (*Backend, error)
GetBackend: get a backend in a given load balancer
func (*ZonedAPI) GetCertificate ¶
func (s *ZonedAPI) GetCertificate(req *ZonedAPIGetCertificateRequest, opts ...scw.RequestOption) (*Certificate, error)
GetCertificate: get a TLS certificate
func (*ZonedAPI) GetFrontend ¶
func (s *ZonedAPI) GetFrontend(req *ZonedAPIGetFrontendRequest, opts ...scw.RequestOption) (*Frontend, error)
GetFrontend: get a frontend
func (*ZonedAPI) GetIP ¶
func (s *ZonedAPI) GetIP(req *ZonedAPIGetIPRequest, opts ...scw.RequestOption) (*IP, error)
GetIP: get an IP
func (*ZonedAPI) GetLB ¶
func (s *ZonedAPI) GetLB(req *ZonedAPIGetLBRequest, opts ...scw.RequestOption) (*LB, error)
GetLB: get a load balancer
func (*ZonedAPI) GetLBStats
deprecated
func (s *ZonedAPI) GetLBStats(req *ZonedAPIGetLBStatsRequest, opts ...scw.RequestOption) (*LBStats, error)
Deprecated: GetLBStats: get usage statistics of a given load balancer
func (*ZonedAPI) GetRoute ¶
func (s *ZonedAPI) GetRoute(req *ZonedAPIGetRouteRequest, opts ...scw.RequestOption) (*Route, error)
GetRoute: get single backend redirection
func (*ZonedAPI) GetSubscriber ¶
func (s *ZonedAPI) GetSubscriber(req *ZonedAPIGetSubscriberRequest, opts ...scw.RequestOption) (*Subscriber, error)
GetSubscriber: get a subscriber
func (*ZonedAPI) ListACLs ¶
func (s *ZonedAPI) ListACLs(req *ZonedAPIListACLsRequest, opts ...scw.RequestOption) (*ListACLResponse, error)
ListACLs: list ACL for a given frontend
func (*ZonedAPI) ListBackendStats ¶
func (s *ZonedAPI) ListBackendStats(req *ZonedAPIListBackendStatsRequest, opts ...scw.RequestOption) (*ListBackendStatsResponse, error)
func (*ZonedAPI) ListBackends ¶
func (s *ZonedAPI) ListBackends(req *ZonedAPIListBackendsRequest, opts ...scw.RequestOption) (*ListBackendsResponse, error)
ListBackends: list backends in a given load balancer
func (*ZonedAPI) ListCertificates ¶
func (s *ZonedAPI) ListCertificates(req *ZonedAPIListCertificatesRequest, opts ...scw.RequestOption) (*ListCertificatesResponse, error)
ListCertificates: list all TLS certificates on a given load balancer
func (*ZonedAPI) ListFrontends ¶
func (s *ZonedAPI) ListFrontends(req *ZonedAPIListFrontendsRequest, opts ...scw.RequestOption) (*ListFrontendsResponse, error)
ListFrontends: list frontends in a given load balancer
func (*ZonedAPI) ListIPs ¶
func (s *ZonedAPI) ListIPs(req *ZonedAPIListIPsRequest, opts ...scw.RequestOption) (*ListIPsResponse, error)
ListIPs: list IPs
func (*ZonedAPI) ListLBPrivateNetworks ¶
func (s *ZonedAPI) ListLBPrivateNetworks(req *ZonedAPIListLBPrivateNetworksRequest, opts ...scw.RequestOption) (*ListLBPrivateNetworksResponse, error)
ListLBPrivateNetworks: list attached private network of load balancer
func (*ZonedAPI) ListLBTypes ¶
func (s *ZonedAPI) ListLBTypes(req *ZonedAPIListLBTypesRequest, opts ...scw.RequestOption) (*ListLBTypesResponse, error)
ListLBTypes: list all load balancer offer type
func (*ZonedAPI) ListLBs ¶
func (s *ZonedAPI) ListLBs(req *ZonedAPIListLBsRequest, opts ...scw.RequestOption) (*ListLBsResponse, error)
ListLBs: list load balancers
func (*ZonedAPI) ListRoutes ¶
func (s *ZonedAPI) ListRoutes(req *ZonedAPIListRoutesRequest, opts ...scw.RequestOption) (*ListRoutesResponse, error)
ListRoutes: list all backend redirections
func (*ZonedAPI) ListSubscriber ¶
func (s *ZonedAPI) ListSubscriber(req *ZonedAPIListSubscriberRequest, opts ...scw.RequestOption) (*ListSubscriberResponse, error)
ListSubscriber: list all subscriber
func (*ZonedAPI) MigrateLB ¶
func (s *ZonedAPI) MigrateLB(req *ZonedAPIMigrateLBRequest, opts ...scw.RequestOption) (*LB, error)
MigrateLB: migrate a load balancer
func (*ZonedAPI) ReleaseIP ¶
func (s *ZonedAPI) ReleaseIP(req *ZonedAPIReleaseIPRequest, opts ...scw.RequestOption) error
ReleaseIP: delete an IP
func (*ZonedAPI) RemoveBackendServers ¶
func (s *ZonedAPI) RemoveBackendServers(req *ZonedAPIRemoveBackendServersRequest, opts ...scw.RequestOption) (*Backend, error)
RemoveBackendServers: remove a set of servers for a given backend
func (*ZonedAPI) SetACLs ¶
func (s *ZonedAPI) SetACLs(req *ZonedAPISetACLsRequest, opts ...scw.RequestOption) (*SetACLsResponse, error)
SetACLs: set all ACLs for a given frontend
func (*ZonedAPI) SetBackendServers ¶
func (s *ZonedAPI) SetBackendServers(req *ZonedAPISetBackendServersRequest, opts ...scw.RequestOption) (*Backend, error)
SetBackendServers: define all servers in a given backend
func (*ZonedAPI) SubscribeToLB ¶
func (s *ZonedAPI) SubscribeToLB(req *ZonedAPISubscribeToLBRequest, opts ...scw.RequestOption) (*LB, error)
SubscribeToLB: subscribe a subscriber to a given load balancer
func (*ZonedAPI) UnsubscribeFromLB ¶
func (s *ZonedAPI) UnsubscribeFromLB(req *ZonedAPIUnsubscribeFromLBRequest, opts ...scw.RequestOption) (*LB, error)
UnsubscribeFromLB: unsubscribe a subscriber from a given load balancer
func (*ZonedAPI) UpdateACL ¶
func (s *ZonedAPI) UpdateACL(req *ZonedAPIUpdateACLRequest, opts ...scw.RequestOption) (*ACL, error)
UpdateACL: update an ACL
func (*ZonedAPI) UpdateBackend ¶
func (s *ZonedAPI) UpdateBackend(req *ZonedAPIUpdateBackendRequest, opts ...scw.RequestOption) (*Backend, error)
UpdateBackend: update a backend in a given load balancer
func (*ZonedAPI) UpdateCertificate ¶
func (s *ZonedAPI) UpdateCertificate(req *ZonedAPIUpdateCertificateRequest, opts ...scw.RequestOption) (*Certificate, error)
UpdateCertificate: update a TLS certificate
func (*ZonedAPI) UpdateFrontend ¶
func (s *ZonedAPI) UpdateFrontend(req *ZonedAPIUpdateFrontendRequest, opts ...scw.RequestOption) (*Frontend, error)
UpdateFrontend: update a frontend
func (*ZonedAPI) UpdateHealthCheck ¶
func (s *ZonedAPI) UpdateHealthCheck(req *ZonedAPIUpdateHealthCheckRequest, opts ...scw.RequestOption) (*HealthCheck, error)
UpdateHealthCheck: update an healthcheck for a given backend
func (*ZonedAPI) UpdateIP ¶
func (s *ZonedAPI) UpdateIP(req *ZonedAPIUpdateIPRequest, opts ...scw.RequestOption) (*IP, error)
UpdateIP: update an IP
func (*ZonedAPI) UpdateLB ¶
func (s *ZonedAPI) UpdateLB(req *ZonedAPIUpdateLBRequest, opts ...scw.RequestOption) (*LB, error)
UpdateLB: update a load balancer
func (*ZonedAPI) UpdateRoute ¶
func (s *ZonedAPI) UpdateRoute(req *ZonedAPIUpdateRouteRequest, opts ...scw.RequestOption) (*Route, error)
UpdateRoute: edit a backend redirection
func (*ZonedAPI) UpdateSubscriber ¶
func (s *ZonedAPI) UpdateSubscriber(req *ZonedAPIUpdateSubscriberRequest, opts ...scw.RequestOption) (*Subscriber, error)
UpdateSubscriber: update a subscriber
func (*ZonedAPI) WaitForLBCertificate ¶
func (s *ZonedAPI) WaitForLBCertificate(req *ZonedAPIWaitForLBCertificateRequest, opts ...scw.RequestOption) (*Certificate, error)
WaitForLBCertificate waits for the certificate to be in a "terminal state"
func (*ZonedAPI) WaitForLBPN ¶
func (s *ZonedAPI) WaitForLBPN(req *ZonedAPIWaitForLBPNRequest, opts ...scw.RequestOption) ([]*PrivateNetwork, error)
WaitForLBPN waits for the private_network attached status on a load balancer to be in a "terminal state" before returning. This function can be used to wait for an attached private_network to be ready for example.
func (*ZonedAPI) WaitForLb ¶
func (s *ZonedAPI) WaitForLb(req *ZonedAPIWaitForLBRequest, opts ...scw.RequestOption) (*LB, error)
WaitForLb waits for the lb to be in a "terminal state" before returning. This function can be used to wait for a lb to be ready for example.
func (*ZonedAPI) WaitForLbInstances ¶
func (s *ZonedAPI) WaitForLbInstances(req *ZonedAPIWaitForLBInstancesRequest, opts ...scw.RequestOption) (*LB, error)
WaitForLbInstances waits for the lb to be in a "terminal state" and the attached instances before returning.
type ZonedAPIAttachPrivateNetworkRequest ¶
type ZonedAPIAttachPrivateNetworkRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// LBID: load balancer ID
LBID string `json:"-"`
// PrivateNetworkID: set your instance private network id
PrivateNetworkID string `json:"-"`
// StaticConfig: define two local ip address of your choice for each load balancer instance
// Precisely one of DHCPConfig, StaticConfig must be set.
StaticConfig *PrivateNetworkStaticConfig `json:"static_config,omitempty"`
// DHCPConfig: set to true if you want to let DHCP assign IP addresses
// Precisely one of DHCPConfig, StaticConfig must be set.
DHCPConfig *PrivateNetworkDHCPConfig `json:"dhcp_config,omitempty"`
}
type ZonedAPICreateACLRequest ¶
type ZonedAPICreateACLRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// FrontendID: ID of your frontend
FrontendID string `json:"-"`
// Name: name of your ACL ressource
Name string `json:"name"`
// Action: action to undertake when an ACL filter matches
Action *ACLAction `json:"action"`
// Match: the ACL match rule
//
// The ACL match rule. You can have one of those three cases:
//
// - `ip_subnet` is defined
// - `http_filter` and `http_filter_value` are defined
// - `ip_subnet`, `http_filter` and `http_filter_value` are defined
//
Match *ACLMatch `json:"match"`
// Index: order between your Acls (ascending order, 0 is first acl executed)
Index int32 `json:"index"`
// Description: description of your ACL ressource
Description string `json:"description"`
}
type ZonedAPICreateBackendRequest ¶
type ZonedAPICreateBackendRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `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 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"`
// Deprecated: SendProxyV2: deprecated in favor of proxy_protocol field !
SendProxyV2 *bool `json:"send_proxy_v2,omitempty"`
// TimeoutServer: maximum server connection inactivity time (allowed time the server has to process the request)
TimeoutServer *time.Duration `json:"timeout_server"`
// TimeoutConnect: maximum initial server connection establishment time
TimeoutConnect *time.Duration `json:"timeout_connect"`
// TimeoutTunnel: maximum tunnel inactivity time after Websocket is established (take precedence over client and server timeout)
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"`
// ProxyProtocol: pROXY protocol, forward client's address (must be supported by backend servers software)
//
// The PROXY protocol informs the other end about the incoming connection, so that it can know the client's address or the public address it accessed to, whatever the upper layer protocol.
//
// * `proxy_protocol_none` Disable proxy protocol.
// * `proxy_protocol_v1` Version one (text format).
// * `proxy_protocol_v2` Version two (binary format).
// * `proxy_protocol_v2_ssl` Version two with SSL connection.
// * `proxy_protocol_v2_ssl_cn` Version two with SSL connection and common name information.
//
// Default value: proxy_protocol_unknown
ProxyProtocol ProxyProtocol `json:"proxy_protocol"`
// FailoverHost: scaleway S3 bucket website to be served in case all backend servers are down
//
// Only the host part of the Scaleway S3 bucket website is expected.
// E.g. `failover-website.s3-website.fr-par.scw.cloud` if your bucket website URL is `https://failover-website.s3-website.fr-par.scw.cloud/`.
//
FailoverHost *string `json:"failover_host"`
// SslBridging: enable SSL between load balancer and backend servers
SslBridging *bool `json:"ssl_bridging"`
// IgnoreSslServerVerify: set to true to ignore server certificate verification
IgnoreSslServerVerify *bool `json:"ignore_ssl_server_verify"`
}
func (ZonedAPICreateBackendRequest) MarshalJSON ¶
func (m ZonedAPICreateBackendRequest) MarshalJSON() ([]byte, error)
func (*ZonedAPICreateBackendRequest) UnmarshalJSON ¶
func (m *ZonedAPICreateBackendRequest) UnmarshalJSON(b []byte) error
type ZonedAPICreateCertificateRequest ¶
type ZonedAPICreateCertificateRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// LBID: load balancer ID
LBID string `json:"-"`
// Name: certificate name
Name string `json:"name"`
// Letsencrypt: let's Encrypt type
// Precisely one of CustomCertificate, Letsencrypt must be set.
Letsencrypt *CreateCertificateRequestLetsencryptConfig `json:"letsencrypt,omitempty"`
// CustomCertificate: custom import certificate
// Precisely one of CustomCertificate, Letsencrypt must be set.
CustomCertificate *CreateCertificateRequestCustomCertificate `json:"custom_certificate,omitempty"`
}
type ZonedAPICreateFrontendRequest ¶
type ZonedAPICreateFrontendRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `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"`
// Deprecated: CertificateID: certificate ID, deprecated in favor of certificate_ids array !
CertificateID *string `json:"certificate_id,omitempty"`
// CertificateIDs: list of certificate IDs to bind on the frontend
CertificateIDs *[]string `json:"certificate_ids"`
// EnableHTTP3: activate HTTP 3 protocol (beta)
EnableHTTP3 bool `json:"enable_http3"`
}
func (ZonedAPICreateFrontendRequest) MarshalJSON ¶
func (m ZonedAPICreateFrontendRequest) MarshalJSON() ([]byte, error)
func (*ZonedAPICreateFrontendRequest) UnmarshalJSON ¶
func (m *ZonedAPICreateFrontendRequest) UnmarshalJSON(b []byte) error
type ZonedAPICreateIPRequest ¶
type ZonedAPICreateIPRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// Deprecated: OrganizationID: owner of resources
// Precisely one of OrganizationID, ProjectID must be set.
OrganizationID *string `json:"organization_id,omitempty"`
// ProjectID: assign the resource to a project ID
// Precisely one of OrganizationID, ProjectID must be set.
ProjectID *string `json:"project_id,omitempty"`
// Reverse: reverse domain name
Reverse *string `json:"reverse"`
}
type ZonedAPICreateLBRequest ¶
type ZonedAPICreateLBRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// Deprecated: OrganizationID: owner of resources
// Precisely one of OrganizationID, ProjectID must be set.
OrganizationID *string `json:"organization_id,omitempty"`
// ProjectID: assign the resource to a project ID
// Precisely one of OrganizationID, ProjectID must be set.
ProjectID *string `json:"project_id,omitempty"`
// 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"`
// SslCompatibilityLevel:
//
// Enforces minimal SSL version (in SSL/TLS offloading context).
// - `intermediate` General-purpose servers with a variety of clients, recommended for almost all systems (Supports Firefox 27, Android 4.4.2, Chrome 31, Edge, IE 11 on Windows 7, Java 8u31, OpenSSL 1.0.1, Opera 20, and Safari 9).
// - `modern` Services with clients that support TLS 1.3 and don't need backward compatibility (Firefox 63, Android 10.0, Chrome 70, Edge 75, Java 11, OpenSSL 1.1.1, Opera 57, and Safari 12.1).
// - `old` Compatible with a number of very old clients, and should be used only as a last resort (Firefox 1, Android 2.3, Chrome 1, Edge 12, IE8 on Windows XP, Java 6, OpenSSL 0.9.8, Opera 5, and Safari 1).
//
// Default value: ssl_compatibility_level_unknown
SslCompatibilityLevel SSLCompatibilityLevel `json:"ssl_compatibility_level"`
}
type ZonedAPICreateRouteRequest ¶
type ZonedAPICreateRouteRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// FrontendID: origin of redirection
FrontendID string `json:"frontend_id"`
// BackendID: destination of destination
BackendID string `json:"backend_id"`
// Match: value to match a redirection
Match *RouteMatch `json:"match"`
}
type ZonedAPICreateSubscriberRequest ¶
type ZonedAPICreateSubscriberRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// Name: subscriber name
Name string `json:"name"`
// EmailConfig: email address configuration
// Precisely one of EmailConfig, WebhookConfig must be set.
EmailConfig *SubscriberEmailConfig `json:"email_config,omitempty"`
// WebhookConfig: webHook URI configuration
// Precisely one of EmailConfig, WebhookConfig must be set.
WebhookConfig *SubscriberWebhookConfig `json:"webhook_config,omitempty"`
// Deprecated: OrganizationID: owner of resources
// Precisely one of OrganizationID, ProjectID must be set.
OrganizationID *string `json:"organization_id,omitempty"`
// ProjectID: assign the resource to a project ID
// Precisely one of OrganizationID, ProjectID must be set.
ProjectID *string `json:"project_id,omitempty"`
}
type ZonedAPIDeleteLBRequest ¶
type ZonedAPIDetachPrivateNetworkRequest ¶
type ZonedAPIDetachPrivateNetworkRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// LBID: load balancer ID
LBID string `json:"-"`
// PrivateNetworkID: set your instance private network id
PrivateNetworkID string `json:"-"`
}
type ZonedAPIGetACLRequest ¶
type ZonedAPIGetIPRequest ¶
type ZonedAPIGetLBRequest ¶
type ZonedAPIGetRouteRequest ¶
type ZonedAPIListACLsRequest ¶
type ZonedAPIListACLsRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// FrontendID: ID of your frontend
FrontendID string `json:"-"`
// OrderBy: response order
//
// Default value: created_at_asc
OrderBy ListACLRequestOrderBy `json:"-"`
// Page: page number
Page *int32 `json:"-"`
// PageSize: the number of items to return
PageSize *uint32 `json:"-"`
// Name: filter acl per name
Name *string `json:"-"`
}
type ZonedAPIListBackendStatsRequest ¶
type ZonedAPIListBackendStatsRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// LBID: load balancer ID
LBID string `json:"-"`
// Page: page number
Page *int32 `json:"-"`
// PageSize: the number of items to return
PageSize *uint32 `json:"-"`
}
type ZonedAPIListBackendsRequest ¶
type ZonedAPIListBackendsRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `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 ListBackendsRequestOrderBy `json:"-"`
// Page: page number
Page *int32 `json:"-"`
// PageSize: the number of items to return
PageSize *uint32 `json:"-"`
}
type ZonedAPIListCertificatesRequest ¶
type ZonedAPIListCertificatesRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// LBID: load balancer ID
LBID string `json:"-"`
// OrderBy: response order
//
// Default value: created_at_asc
OrderBy ListCertificatesRequestOrderBy `json:"-"`
// Page: page number
Page *int32 `json:"-"`
// PageSize: the number of items to return
PageSize *uint32 `json:"-"`
// Name: use this to search by name
Name *string `json:"-"`
}
type ZonedAPIListFrontendsRequest ¶
type ZonedAPIListFrontendsRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `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: the number of items to return
PageSize *uint32 `json:"-"`
}
type ZonedAPIListIPsRequest ¶
type ZonedAPIListIPsRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// Page: page number
Page *int32 `json:"-"`
// PageSize: the number of items to return
PageSize *uint32 `json:"-"`
// IPAddress: use this to search by IP address
IPAddress *string `json:"-"`
// OrganizationID: filter IPs by organization id
OrganizationID *string `json:"-"`
// ProjectID: filter IPs by project ID
ProjectID *string `json:"-"`
}
type ZonedAPIListLBPrivateNetworksRequest ¶
type ZonedAPIListLBPrivateNetworksRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// LBID: load balancer ID
LBID string `json:"-"`
// OrderBy: response order
//
// Default value: created_at_asc
OrderBy ListPrivateNetworksRequestOrderBy `json:"-"`
// PageSize: the number of items to return
PageSize *uint32 `json:"-"`
// Page: page number
Page *int32 `json:"-"`
}
type ZonedAPIListLBsRequest ¶
type ZonedAPIListLBsRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// Name: use this to search by name
Name *string `json:"-"`
// OrderBy: response order
//
// Default value: created_at_asc
OrderBy ListLBsRequestOrderBy `json:"-"`
// PageSize: the number of items to return
PageSize *uint32 `json:"-"`
// Page: page number
Page *int32 `json:"-"`
// OrganizationID: filter LBs by organization ID
OrganizationID *string `json:"-"`
// ProjectID: filter LBs by project ID
ProjectID *string `json:"-"`
}
type ZonedAPIListRoutesRequest ¶
type ZonedAPIListRoutesRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// OrderBy: response order
//
// Default value: created_at_asc
OrderBy ListRoutesRequestOrderBy `json:"-"`
// PageSize: the number of items to return
PageSize *uint32 `json:"-"`
// Page: page number
Page *int32 `json:"-"`
FrontendID *string `json:"-"`
}
type ZonedAPIListSubscriberRequest ¶
type ZonedAPIListSubscriberRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// OrderBy: response order
//
// Default value: created_at_asc
OrderBy ListSubscriberRequestOrderBy `json:"-"`
// Page: page number
Page *int32 `json:"-"`
// PageSize: the number of items to return
PageSize *uint32 `json:"-"`
// Name: use this to search by name
Name *string `json:"-"`
// OrganizationID: filter Subscribers by organization ID
OrganizationID *string `json:"-"`
// ProjectID: filter Subscribers by project ID
ProjectID *string `json:"-"`
}
type ZonedAPIRemoveBackendServersRequest ¶
type ZonedAPIRemoveBackendServersRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// BackendID: backend ID
BackendID string `json:"-"`
// ServerIP: set all IPs to remove of your backend
ServerIP []string `json:"server_ip"`
}
type ZonedAPISetACLsRequest ¶
type ZonedAPISetACLsRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// FrontendID: the Frontend to change ACL to
FrontendID string `json:"-"`
// ACLs: array of ACLs to erease the existing ACLs
ACLs []*ACLSpec `json:"acls"`
}
type ZonedAPISetBackendServersRequest ¶
type ZonedAPISetBackendServersRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// BackendID: backend ID
BackendID string `json:"-"`
// ServerIP: set all IPs to add on your backend and remove all other
ServerIP []string `json:"server_ip"`
}
type ZonedAPIUpdateACLRequest ¶
type ZonedAPIUpdateACLRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// ACLID: ID of your ACL ressource
ACLID string `json:"-"`
// Name: name of your ACL ressource
Name string `json:"name"`
// Action: action to undertake when an ACL filter matches
Action *ACLAction `json:"action"`
// Match: the ACL match rule. At least `ip_subnet` or `http_filter` and `http_filter_value` are required
Match *ACLMatch `json:"match"`
// Index: order between your Acls (ascending order, 0 is first acl executed)
Index int32 `json:"index"`
// Description: description of your ACL ressource
Description *string `json:"description"`
}
type ZonedAPIUpdateBackendRequest ¶
type ZonedAPIUpdateBackendRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `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 sticky sessions
StickySessionsCookieName string `json:"sticky_sessions_cookie_name"`
// Deprecated: SendProxyV2: deprecated in favor of proxy_protocol field!
SendProxyV2 *bool `json:"send_proxy_v2,omitempty"`
// TimeoutServer: maximum server connection inactivity time (allowed time the server has to process the request)
TimeoutServer *time.Duration `json:"timeout_server"`
// TimeoutConnect: maximum initial server connection establishment time
TimeoutConnect *time.Duration `json:"timeout_connect"`
// TimeoutTunnel: maximum tunnel inactivity time after Websocket is established (take precedence over client and server timeout)
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"`
// ProxyProtocol: pROXY protocol, forward client's address (must be supported by backend servers software)
//
// The PROXY protocol informs the other end about the incoming connection, so that it can know the client's address or the public address it accessed to, whatever the upper layer protocol is.
//
// * `proxy_protocol_none` Disable proxy protocol.
// * `proxy_protocol_v1` Version one (text format).
// * `proxy_protocol_v2` Version two (binary format).
// * `proxy_protocol_v2_ssl` Version two with SSL connection.
// * `proxy_protocol_v2_ssl_cn` Version two with SSL connection and common name information.
//
// Default value: proxy_protocol_unknown
ProxyProtocol ProxyProtocol `json:"proxy_protocol"`
// FailoverHost: scaleway S3 bucket website to be served in case all backend servers are down
//
// Only the host part of the Scaleway S3 bucket website is expected.
// Example: `failover-website.s3-website.fr-par.scw.cloud` if your bucket website URL is `https://failover-website.s3-website.fr-par.scw.cloud/`.
//
FailoverHost *string `json:"failover_host"`
// SslBridging: enable SSL between load balancer and backend servers
SslBridging *bool `json:"ssl_bridging"`
// IgnoreSslServerVerify: set to true to ignore server certificate verification
IgnoreSslServerVerify *bool `json:"ignore_ssl_server_verify"`
}
func (ZonedAPIUpdateBackendRequest) MarshalJSON ¶
func (m ZonedAPIUpdateBackendRequest) MarshalJSON() ([]byte, error)
func (*ZonedAPIUpdateBackendRequest) UnmarshalJSON ¶
func (m *ZonedAPIUpdateBackendRequest) UnmarshalJSON(b []byte) error
type ZonedAPIUpdateFrontendRequest ¶
type ZonedAPIUpdateFrontendRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `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"`
// Deprecated: CertificateID: certificate ID, deprecated in favor of `certificate_ids` array!
CertificateID *string `json:"certificate_id,omitempty"`
// CertificateIDs: list of certificate IDs to bind on the frontend
CertificateIDs *[]string `json:"certificate_ids"`
// EnableHTTP3: activate HTTP 3 protocol (beta)
EnableHTTP3 bool `json:"enable_http3"`
}
func (ZonedAPIUpdateFrontendRequest) MarshalJSON ¶
func (m ZonedAPIUpdateFrontendRequest) MarshalJSON() ([]byte, error)
func (*ZonedAPIUpdateFrontendRequest) UnmarshalJSON ¶
func (m *ZonedAPIUpdateFrontendRequest) UnmarshalJSON(b []byte) error
type ZonedAPIUpdateHealthCheckRequest ¶
type ZonedAPIUpdateHealthCheckRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `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: maximum time a backend server has to reply to the health check
CheckTimeout *time.Duration `json:"check_timeout"`
// CheckMaxRetries: number of consecutive unsuccessful health checks, after which 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"`
// PgsqlConfig: postgreSQL health check
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
PgsqlConfig *HealthCheckPgsqlConfig `json:"pgsql_config,omitempty"`
// TCPConfig: basic TCP health check
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
TCPConfig *HealthCheckTCPConfig `json:"tcp_config,omitempty"`
// HTTPConfig: HTTP health check
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
HTTPConfig *HealthCheckHTTPConfig `json:"http_config,omitempty"`
// HTTPSConfig: HTTPS health check
// Precisely one of HTTPConfig, HTTPSConfig, LdapConfig, MysqlConfig, PgsqlConfig, RedisConfig, TCPConfig must be set.
HTTPSConfig *HealthCheckHTTPSConfig `json:"https_config,omitempty"`
// CheckSendProxy: it defines whether the health check should be done considering the proxy protocol
CheckSendProxy bool `json:"check_send_proxy"`
}
func (ZonedAPIUpdateHealthCheckRequest) MarshalJSON ¶
func (m ZonedAPIUpdateHealthCheckRequest) MarshalJSON() ([]byte, error)
func (*ZonedAPIUpdateHealthCheckRequest) UnmarshalJSON ¶
func (m *ZonedAPIUpdateHealthCheckRequest) UnmarshalJSON(b []byte) error
type ZonedAPIUpdateIPRequest ¶
type ZonedAPIUpdateLBRequest ¶
type ZonedAPIUpdateLBRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// LBID: load balancer ID
LBID string `json:"-"`
// Name: resource name
Name string `json:"name"`
// Description: resource description
Description string `json:"description"`
// Tags: list of keywords
Tags []string `json:"tags"`
// SslCompatibilityLevel:
//
// Enforces minimal SSL version (in SSL/TLS offloading context).
// - `intermediate` General-purpose servers with a variety of clients, recommended for almost all systems (Supports Firefox 27, Android 4.4.2, Chrome 31, Edge, IE 11 on Windows 7, Java 8u31, OpenSSL 1.0.1, Opera 20, and Safari 9).
// - `modern` Services with clients that support TLS 1.3 and don't need backward compatibility (Firefox 63, Android 10.0, Chrome 70, Edge 75, Java 11, OpenSSL 1.1.1, Opera 57, and Safari 12.1).
// - `old` Compatible with a number of very old clients, and should be used only as a last resort (Firefox 1, Android 2.3, Chrome 1, Edge 12, IE8 on Windows XP, Java 6, OpenSSL 0.9.8, Opera 5, and Safari 1).
//
// Default value: ssl_compatibility_level_unknown
SslCompatibilityLevel SSLCompatibilityLevel `json:"ssl_compatibility_level"`
}
type ZonedAPIUpdateRouteRequest ¶
type ZonedAPIUpdateRouteRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// RouteID: route id to update
RouteID string `json:"-"`
// BackendID: backend id of redirection
BackendID string `json:"backend_id"`
// Match: value to match a redirection
Match *RouteMatch `json:"match"`
}
type ZonedAPIUpdateSubscriberRequest ¶
type ZonedAPIUpdateSubscriberRequest struct {
// Zone:
//
// Zone to target. If none is passed will use default zone from the config
Zone scw.Zone `json:"-"`
// SubscriberID: assign the resource to a project IDs
SubscriberID string `json:"-"`
// Name: subscriber name
Name string `json:"name"`
// EmailConfig: email address configuration
// Precisely one of EmailConfig, WebhookConfig must be set.
EmailConfig *SubscriberEmailConfig `json:"email_config,omitempty"`
// WebhookConfig: webHook URI configuration
// Precisely one of EmailConfig, WebhookConfig must be set.
WebhookConfig *SubscriberWebhookConfig `json:"webhook_config,omitempty"`
}
type ZonedAPIWaitForLBCertificateRequest ¶
type ZonedAPIWaitForLBCertificateRequest struct {
CertID string
Zone scw.Zone
Timeout *time.Duration
RetryInterval *time.Duration
}
ZonedAPIWaitForLBCertificateRequest is used by WaitForLbCertificate method.
type ZonedAPIWaitForLBInstancesRequest ¶
type ZonedAPIWaitForLBInstancesRequest struct {
LBID string
Zone scw.Zone
Timeout *time.Duration
RetryInterval *time.Duration
}
ZonedAPIWaitForLBInstancesRequest is used by WaitForLb method.