aws

package
v0.0.0-...-123c96e Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2024 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DescribeFirewallAPIClient

type DescribeFirewallAPIClient interface {
	DescribeFirewall(ctx context.Context, params *networkfirewall.DescribeFirewallInput, optFns ...func(*networkfirewall.Options)) (*networkfirewall.DescribeFirewallOutput, error)
}

DescribeFirewallAPIClient is a client that implements the DescribeFirewall operation.

type DescribeFirewallPolicyAPIClient

type DescribeFirewallPolicyAPIClient interface {
	DescribeFirewallPolicy(ctx context.Context, params *networkfirewall.DescribeFirewallPolicyInput, optFns ...func(*networkfirewall.Options)) (*networkfirewall.DescribeFirewallPolicyOutput, error)
}

DescribeFirewallPolicyAPIClient is a client that implements the DescribeFirewallPolicy operation.

type FirewallDeletedWaiter

type FirewallDeletedWaiter struct {
	// contains filtered or unexported fields
}

FirewallDeletedWaiter defines the waiters for FirewallDeleted

func NewFirewallDeletedWaiter

func NewFirewallDeletedWaiter(client DescribeFirewallAPIClient, optFns ...func(options *FirewallDeletedWaiterOptions)) *FirewallDeletedWaiter

NewFirewallDeletedWaiter constructs a FirewallDeletedWaiter.

func (*FirewallDeletedWaiter) Wait

Wait calls the waiter function for FirewallDeleted waiter. The maxWaitDur is the maximum wait duration the waiter will wait. The maxWaitDur is required and must be greater than zero.

func (*FirewallDeletedWaiter) WaitForOutput

WaitForOutput calls the waiter function for FirewallDeleted waiter and returns the output of the successful operation. The maxWaitDur is the maximum wait duration the waiter will wait. The maxWaitDur is required and must be greater than zero.

type FirewallDeletedWaiterOptions

type FirewallDeletedWaiterOptions struct {
	// Set of options to modify how an operation is invoked. These apply to all
	// operations invoked for this client. Use functional options on operation call to
	// modify this list for per operation behavior.
	APIOptions []func(*middleware.Stack) error

	// MinDelay is the minimum amount of time to delay between retries. If unset,
	// FirewallDeletedWaiter will use default minimum delay of 15 seconds. Note
	// that MinDelay must resolve to a value lesser than or equal to the MaxDelay.
	MinDelay time.Duration

	// MaxDelay is the maximum amount of time to delay between retries. If unset or set
	// to zero, FirewallDeletedWaiter will use default max delay of 120 seconds.
	// Note that MaxDelay must resolve to value greater than or equal to the MinDelay.
	MaxDelay time.Duration

	// LogWaitAttempts is used to enable logging for waiter retry attempts
	LogWaitAttempts bool

	// Retryable is function that can be used to override the service defined
	// waiter-behavior based on operation output, or returned error. This function is
	// used by the waiter to decide if a state is retryable or a terminal state. By
	// default service-modeled logic will populate this option. This option can thus be
	// used to define a custom waiter state with fall-back to service-modeled waiter
	// state mutators.The function returns an error in case of a failure state. In case
	// of retry state, this function returns a bool value of true and nil error, while
	// in case of success it returns a bool value of false and nil error.
	Retryable func(context.Context, *networkfirewall.DescribeFirewallInput, *networkfirewall.DescribeFirewallOutput, error) (bool, error)
}

FirewallDeletedWaiterOptions are waiter options for FirewallDeletedWaiter

type FirewallPolicyDeletedWaiter

type FirewallPolicyDeletedWaiter struct {
	// contains filtered or unexported fields
}

FirewallPolicyDeletedWaiter defines the waiters for FirewallPolicyDeleted

func NewFirewallPolicyDeletedWaiter

func NewFirewallPolicyDeletedWaiter(client DescribeFirewallPolicyAPIClient, optFns ...func(options *FirewallPolicyDeletedWaiterOptions)) *FirewallPolicyDeletedWaiter

NewFirewallPolicyDeletedWaiter constructs a FirewallPolicyDeletedWaiter.

func (*FirewallPolicyDeletedWaiter) Wait

Wait calls the waiter function for FirewallPolicyDeleted waiter. The maxWaitDur is the maximum wait duration the waiter will wait. The maxWaitDur is required and must be greater than zero.

func (*FirewallPolicyDeletedWaiter) WaitForOutput

WaitForOutput calls the waiter function for FirewallPolicyDeleted waiter and returns the output of the successful operation. The maxWaitDur is the maximum wait duration the waiter will wait. The maxWaitDur is required and must be greater than zero.

type FirewallPolicyDeletedWaiterOptions

type FirewallPolicyDeletedWaiterOptions struct {
	// Set of options to modify how an operation is invoked. These apply to all
	// operations invoked for this client. Use functional options on operation call to
	// modify this list for per operation behavior.
	APIOptions []func(*middleware.Stack) error

	// MinDelay is the minimum amount of time to delay between retries. If unset,
	// FirewallPolicyDeletedWaiter will use default minimum delay of 15 seconds. Note
	// that MinDelay must resolve to a value lesser than or equal to the MaxDelay.
	MinDelay time.Duration

	// MaxDelay is the maximum amount of time to delay between retries. If unset or set
	// to zero, FirewallPolicyDeletedWaiter will use default max delay of 120 seconds.
	// Note that MaxDelay must resolve to value greater than or equal to the MinDelay.
	MaxDelay time.Duration

	// LogWaitAttempts is used to enable logging for waiter retry attempts
	LogWaitAttempts bool

	// Retryable is function that can be used to override the service defined
	// waiter-behavior based on operation output, or returned error. This function is
	// used by the waiter to decide if a state is retryable or a terminal state. By
	// default service-modeled logic will populate this option. This option can thus be
	// used to define a custom waiter state with fall-back to service-modeled waiter
	// state mutators.The function returns an error in case of a failure state. In case
	// of retry state, this function returns a bool value of true and nil error, while
	// in case of success it returns a bool value of false and nil error.
	Retryable func(context.Context, *networkfirewall.DescribeFirewallPolicyInput, *networkfirewall.DescribeFirewallPolicyOutput, error) (bool, error)
}

FirewallPolicyDeletedWaiterOptions are waiter options for FirewallPolicyDeletedWaiter

type FirewallReadyWaiter

type FirewallReadyWaiter struct {
	// contains filtered or unexported fields
}

FirewallReadyWaiter defines the waiters for FirewallReady

func NewFirewallReadyWaiter

func NewFirewallReadyWaiter(client DescribeFirewallAPIClient, optFns ...func(options *FirewallReadyWaiterOptions)) *FirewallReadyWaiter

NewFirewallReadyWaiter constructs a FirewallReadyWaiter.

func (*FirewallReadyWaiter) Wait

func (w *FirewallReadyWaiter) Wait(ctx context.Context, params *networkfirewall.DescribeFirewallInput, maxWaitDur time.Duration, optFns ...func(options *FirewallReadyWaiterOptions)) error

Wait calls the waiter function for FirewallReady waiter. The maxWaitDur is the maximum wait duration the waiter will wait. The maxWaitDur is required and must be greater than zero.

func (*FirewallReadyWaiter) WaitForOutput

WaitForOutput calls the waiter function for FirewallReady waiter and returns the output of the successful operation. The maxWaitDur is the maximum wait duration the waiter will wait. The maxWaitDur is required and must be greater than zero.

type FirewallReadyWaiterOptions

type FirewallReadyWaiterOptions struct {
	// Set of options to modify how an operation is invoked. These apply to all
	// operations invoked for this client. Use functional options on operation call to
	// modify this list for per operation behavior.
	APIOptions []func(*middleware.Stack) error

	// MinDelay is the minimum amount of time to delay between retries. If unset,
	// FirewallReadyWaiter will use default minimum delay of 15 seconds. Note
	// that MinDelay must resolve to a value lesser than or equal to the MaxDelay.
	MinDelay time.Duration

	// MaxDelay is the maximum amount of time to delay between retries. If unset or set
	// to zero, FirewallReadyWaiter will use default max delay of 120 seconds.
	// Note that MaxDelay must resolve to value greater than or equal to the MinDelay.
	MaxDelay time.Duration

	// LogWaitAttempts is used to enable logging for waiter retry attempts
	LogWaitAttempts bool

	// Retryable is function that can be used to override the service defined
	// waiter-behavior based on operation output, or returned error. This function is
	// used by the waiter to decide if a state is retryable or a terminal state. By
	// default service-modeled logic will populate this option. This option can thus be
	// used to define a custom waiter state with fall-back to service-modeled waiter
	// state mutators.The function returns an error in case of a failure state. In case
	// of retry state, this function returns a bool value of true and nil error, while
	// in case of success it returns a bool value of false and nil error.
	Retryable func(context.Context, *networkfirewall.DescribeFirewallInput, *networkfirewall.DescribeFirewallOutput, error) (bool, error)
}

FirewallReadyWaiterOptions are waiter options for FirewallReadyWaiter

type OnvIntegrationTestData

type OnvIntegrationTestData struct {
	// contains filtered or unexported fields
}

func NewIntegrationTestData

func NewIntegrationTestData(cfg aws.Config) *OnvIntegrationTestData

func (*OnvIntegrationTestData) Cleanup

func (id *OnvIntegrationTestData) Cleanup(ctx context.Context) error

func (*OnvIntegrationTestData) CleanupElasticIp

func (id *OnvIntegrationTestData) CleanupElasticIp(ctx context.Context) error

CleanupElasticIp deletes EIPs that should have previously been associated with NAT Gateways

func (*OnvIntegrationTestData) CleanupFirewall

func (id *OnvIntegrationTestData) CleanupFirewall(ctx context.Context) error

CleanupFirewall deletes all AWS NetworkFirewall Firewalls

func (*OnvIntegrationTestData) CleanupFirewallPolicy

func (id *OnvIntegrationTestData) CleanupFirewallPolicy(ctx context.Context) error

func (*OnvIntegrationTestData) CleanupInternetGateway

func (id *OnvIntegrationTestData) CleanupInternetGateway(ctx context.Context) error

CleanupInternetGateway detaches and deletes the IGW

func (*OnvIntegrationTestData) CleanupNatGateway

func (id *OnvIntegrationTestData) CleanupNatGateway(ctx context.Context) error

CleanupNatGateway deletes NAT Gateways

func (*OnvIntegrationTestData) CleanupRouteTables

func (id *OnvIntegrationTestData) CleanupRouteTables(ctx context.Context) error

CleanupRouteTables disassociates and deletes the subnet route tables

func (*OnvIntegrationTestData) CleanupRuleGroup

func (id *OnvIntegrationTestData) CleanupRuleGroup(ctx context.Context) error

func (*OnvIntegrationTestData) CleanupSecurityGroup

func (id *OnvIntegrationTestData) CleanupSecurityGroup(ctx context.Context) error

func (*OnvIntegrationTestData) CleanupSubnets

func (id *OnvIntegrationTestData) CleanupSubnets(ctx context.Context) error

CleanupSubnets deletes the firewall/public/private subnets

func (*OnvIntegrationTestData) CleanupVpc

func (id *OnvIntegrationTestData) CleanupVpc(ctx context.Context) error

CleanupVpc deletes a VPC Requires CleanupNatGateway, CleanupInternetGateway, CleanupRouteTables, and Cleanup Subnets to be run first

func (*OnvIntegrationTestData) GetPrivateSubnetId

func (id *OnvIntegrationTestData) GetPrivateSubnetId() *string

GetPrivateSubnetId returns the value of privateSubnetId stored in the struct

func (*OnvIntegrationTestData) Setup

func (*OnvIntegrationTestData) SetupAvailabilityZone

func (id *OnvIntegrationTestData) SetupAvailabilityZone(ctx context.Context) error

SetupAvailabilityZone chooses a random available AZ (not requiring opt-in) from the selected region

func (*OnvIntegrationTestData) SetupFirewall

func (id *OnvIntegrationTestData) SetupFirewall(ctx context.Context) error

SetupFirewall creates a firewall, firewall policy, and firewall rule group to block quay.io

func (*OnvIntegrationTestData) SetupInternetGateway

func (id *OnvIntegrationTestData) SetupInternetGateway(ctx context.Context) error

SetupInternetGateway creates an internet gateway, and associates it with the VPC without waiting for association to complete

func (*OnvIntegrationTestData) SetupNatGateway

func (id *OnvIntegrationTestData) SetupNatGateway(ctx context.Context) error

SetupNatGateway creates a public NAT gateway and creates a route in the private subnet route table

func (*OnvIntegrationTestData) SetupRouteTables

func (id *OnvIntegrationTestData) SetupRouteTables(ctx context.Context) error

SetupRouteTables creates two route tables and associates them with the public/private subnets https://docs.aws.amazon.com/network-firewall/latest/developerguide/arch-igw-ngw.html

func (*OnvIntegrationTestData) SetupSubnets

func (id *OnvIntegrationTestData) SetupSubnets(ctx context.Context) error

SetupSubnets creates a public/firewall/private subnets

func (*OnvIntegrationTestData) SetupVpc

func (id *OnvIntegrationTestData) SetupVpc(ctx context.Context) error

SetupVpc creates a VPC and enables DNS support and hostname resolution

Jump to

Keyboard shortcuts

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