Documentation ¶
Index ¶
- Variables
- func GenerateCreateInput(cr *v1alpha1.ForwardingRule, listenerIP string, ...) sdkgo.NetworkLoadBalancerForwardingRule
- func GenerateUpdateInput(cr *v1alpha1.ForwardingRule, listenerIP string, ...) sdkgo.NetworkLoadBalancerForwardingRuleProperties
- func IsUpToDate(cr *v1alpha1.ForwardingRule, observed sdkgo.NetworkLoadBalancerForwardingRule, ...) bool
- func SetStatus(in *v1alpha1.ForwardingRuleObservation, ...)
- type APIClient
- func (cp *APIClient) CheckDuplicateForwardingRule(ctx context.Context, datacenterID, nlbID, ruleName string) (string, error)
- func (cp *APIClient) CreateForwardingRule(ctx context.Context, datacenterID, nlbID string, ...) (sdkgo.NetworkLoadBalancerForwardingRule, error)
- func (cp *APIClient) DeleteForwardingRule(ctx context.Context, datacenterID, nlbID, ruleID string) error
- func (cp *APIClient) GetForwardingRuleByID(ctx context.Context, datacenterID, nlbID, ruleID string) (sdkgo.NetworkLoadBalancerForwardingRule, error)
- func (cp *APIClient) UpdateForwardingRule(ctx context.Context, datacenterID, nlbID, ruleID string, ...) (sdkgo.NetworkLoadBalancerForwardingRule, error)
- type Client
Constants ¶
This section is empty.
Variables ¶
var ErrNotFound = errors.New("forwarding rule not found")
ErrNotFound no Network Load Balancer ForwardingRule rule has been found
Functions ¶
func GenerateCreateInput ¶
func GenerateCreateInput(cr *v1alpha1.ForwardingRule, listenerIP string, targetsIPs map[string]v1alpha1.ForwardingRuleTarget) sdkgo.NetworkLoadBalancerForwardingRule
GenerateCreateInput returns sdkgo.NetworkLoadBalancer for Create requests based on CR spec
func GenerateUpdateInput ¶
func GenerateUpdateInput(cr *v1alpha1.ForwardingRule, listenerIP string, targetsIPs map[string]v1alpha1.ForwardingRuleTarget) sdkgo.NetworkLoadBalancerForwardingRuleProperties
GenerateUpdateInput returns sdkgo.NetworkLoadBalancerProperties for Update requests based on CR spec
func IsUpToDate ¶
func IsUpToDate(cr *v1alpha1.ForwardingRule, observed sdkgo.NetworkLoadBalancerForwardingRule, listenerIP string, targetsIPs map[string]v1alpha1.ForwardingRuleTarget) bool
IsUpToDate returns true if the ForwardingRule is up-to-date or false otherwise
func SetStatus ¶
func SetStatus(in *v1alpha1.ForwardingRuleObservation, rule sdkgo.NetworkLoadBalancerForwardingRule)
SetStatus sets fields of the ForwardingRuleObservation based on sdkgo.NetworkLoadBalancerForwardingRule
Types ¶
type APIClient ¶
type APIClient struct {
*clients.IonosServices
}
APIClient is a wrapper around IONOS Service
func (*APIClient) CheckDuplicateForwardingRule ¶
func (cp *APIClient) CheckDuplicateForwardingRule(ctx context.Context, datacenterID, nlbID, ruleName string) (string, error)
CheckDuplicateForwardingRule returns the ID of the duplicate Forwarding Rule if any, or an error if multiple Forwarding Rules with the same name are found
func (*APIClient) CreateForwardingRule ¶
func (cp *APIClient) CreateForwardingRule(ctx context.Context, datacenterID, nlbID string, rule sdkgo.NetworkLoadBalancerForwardingRule) (sdkgo.NetworkLoadBalancerForwardingRule, error)
CreateForwardingRule based on Datacenter ID, NetworkLoadBalancer ID and ForwardingRule
func (*APIClient) DeleteForwardingRule ¶
func (cp *APIClient) DeleteForwardingRule(ctx context.Context, datacenterID, nlbID, ruleID string) error
DeleteForwardingRule based on Datacenter ID, NetworkLoadBalancer ID and ForwardingRule ID
func (*APIClient) GetForwardingRuleByID ¶
func (cp *APIClient) GetForwardingRuleByID(ctx context.Context, datacenterID, nlbID, ruleID string) (sdkgo.NetworkLoadBalancerForwardingRule, error)
GetForwardingRuleByID based on Datacenter ID, NetworkLoadBalancer ID and ForwardingRule ID
func (*APIClient) UpdateForwardingRule ¶
func (cp *APIClient) UpdateForwardingRule(ctx context.Context, datacenterID, nlbID, ruleID string, ruleProperties sdkgo.NetworkLoadBalancerForwardingRuleProperties) (sdkgo.NetworkLoadBalancerForwardingRule, error)
UpdateForwardingRule based on Datacenter ID, NetworkLoadBalancer ID, ForwardingRule ID and ForwardingRule
type Client ¶
type Client interface { CheckDuplicateForwardingRule(ctx context.Context, datacenterID, nlbID, ruleName string) (string, error) GetForwardingRuleByID(ctx context.Context, datacenterID, nlbID, ruleID string) (sdkgo.NetworkLoadBalancerForwardingRule, error) CreateForwardingRule(ctx context.Context, datacenterID, nlbID string, rule sdkgo.NetworkLoadBalancerForwardingRule) (sdkgo.NetworkLoadBalancerForwardingRule, error) UpdateForwardingRule(ctx context.Context, datacenterID, nlbID, ruleID string, ruleProperties sdkgo.NetworkLoadBalancerForwardingRuleProperties) (sdkgo.NetworkLoadBalancerForwardingRule, error) DeleteForwardingRule(ctx context.Context, datacenterID, nlbID, ruleID string) error }
Client is a wrapper around IONOS Service Network Load Balancer ForwardingRule methods