package config

import "github.com/aws/aws-sdk-go-v2/feature/ec2/imds/internal/config"

Index

Functions

func ResolveEndpointConfig

func ResolveEndpointConfig(sources []interface{}) (value string, found bool, err error)

ResolveEndpointConfig resolves the endpoint from a list of configuration sources.

func ResolveV1FallbackDisabled

func ResolveV1FallbackDisabled(sources []interface{}) (bool, bool)

ResolveV1FallbackDisabled ...

Types

type ClientEnableState

type ClientEnableState uint

ClientEnableState provides an enumeration if the client is enabled, disabled, or default behavior.

const (
	ClientDefaultEnableState ClientEnableState = iota
	ClientDisabled
	ClientEnabled
)

Enumeration values for ClientEnableState

func ResolveClientEnableState

func ResolveClientEnableState(sources []interface{}) (value ClientEnableState, found bool, err error)

ResolveClientEnableState resolves the ClientEnableState from a list of configuration sources.

type ClientEnableStateResolver

type ClientEnableStateResolver interface {
	GetEC2IMDSClientEnableState() (ClientEnableState, bool, error)
}

ClientEnableStateResolver is a config resolver interface for retrieving whether the IMDS client is disabled.

type EndpointModeResolver

type EndpointModeResolver interface {
	GetEC2IMDSEndpointMode() (EndpointModeState, bool, error)
}

EndpointModeResolver is a config resolver interface for retrieving the EndpointModeState configuration.

type EndpointModeState

type EndpointModeState uint

EndpointModeState is the EC2 IMDS Endpoint Configuration Mode

const (
	EndpointModeStateUnset EndpointModeState = iota
	EndpointModeStateIPv4
	EndpointModeStateIPv6
)

Enumeration values for ClientEnableState

func ResolveEndpointModeConfig

func ResolveEndpointModeConfig(sources []interface{}) (value EndpointModeState, found bool, err error)

ResolveEndpointModeConfig resolves the EndpointModeState from a list of configuration sources.

func (*EndpointModeState) SetFromString

func (e *EndpointModeState) SetFromString(v string) error

SetFromString sets the EndpointModeState based on the provided string value. Unknown values will default to EndpointModeStateUnset

type EndpointResolver

type EndpointResolver interface {
	GetEC2IMDSEndpoint() (string, bool, error)
}

EndpointResolver is a config resolver interface for retrieving the endpoint.

Source Files

resolvers.go

Version
v1.16.30 (latest)
Published
Feb 27, 2025
Platform
linux/amd64
Imports
2 packages
Last checked
6 days ago

Tools for package owners.