aws

package
v0.40.0-rc.2 Latest Latest
Warning

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

Go to latest
Published: Feb 26, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DefaultEC2SDConfig = EC2Arguments{
	Port:             80,
	RefreshInterval:  60 * time.Second,
	HTTPClientConfig: config.DefaultHTTPClientConfig,
}
View Source
var DefaultLightsailSDConfig = LightsailArguments{
	Port:             80,
	RefreshInterval:  60 * time.Second,
	HTTPClientConfig: config.DefaultHTTPClientConfig,
}

DefaultLightsailSDConfig is the default Lightsail SD configuration.

Functions

func NewEC2

func NewEC2(opts component.Options, args EC2Arguments) (component.Component, error)

New creates a new discovery.ec2 component.

func NewLightsail

func NewLightsail(opts component.Options, args LightsailArguments) (component.Component, error)

New creates a new discovery.lightsail component.

Types

type EC2Arguments

type EC2Arguments struct {
	Endpoint        string            `river:"endpoint,attr,optional"`
	Region          string            `river:"region,attr,optional"`
	AccessKey       string            `river:"access_key,attr,optional"`
	SecretKey       rivertypes.Secret `river:"secret_key,attr,optional"`
	Profile         string            `river:"profile,attr,optional"`
	RoleARN         string            `river:"role_arn,attr,optional"`
	RefreshInterval time.Duration     `river:"refresh_interval,attr,optional"`
	Port            int               `river:"port,attr,optional"`
	Filters         []*EC2Filter      `river:"filter,block,optional"`

	HTTPClientConfig config.HTTPClientConfig `river:",squash"`
}

EC2Arguments is the configuration for EC2 based service discovery.

func (EC2Arguments) Convert

func (args EC2Arguments) Convert() *promaws.EC2SDConfig

func (*EC2Arguments) SetToDefault added in v0.35.0

func (args *EC2Arguments) SetToDefault()

SetToDefault implements river.Defaulter.

func (*EC2Arguments) Validate added in v0.35.0

func (args *EC2Arguments) Validate() error

Validate implements river.Validator.

type EC2Filter

type EC2Filter struct {
	Name   string   `river:"name,attr"`
	Values []string `river:"values,attr"`
}

EC2Filter is the configuration for filtering EC2 instances.

type LightsailArguments

type LightsailArguments struct {
	Endpoint         string                  `river:"endpoint,attr,optional"`
	Region           string                  `river:"region,attr,optional"`
	AccessKey        string                  `river:"access_key,attr,optional"`
	SecretKey        rivertypes.Secret       `river:"secret_key,attr,optional"`
	Profile          string                  `river:"profile,attr,optional"`
	RoleARN          string                  `river:"role_arn,attr,optional"`
	RefreshInterval  time.Duration           `river:"refresh_interval,attr,optional"`
	Port             int                     `river:"port,attr,optional"`
	HTTPClientConfig config.HTTPClientConfig `river:",squash"`
}

LightsailArguments is the configuration for AWS Lightsail based service discovery.

func (LightsailArguments) Convert

func (*LightsailArguments) SetToDefault added in v0.35.0

func (args *LightsailArguments) SetToDefault()

SetToDefault implements river.Defaulter.

func (*LightsailArguments) Validate added in v0.35.0

func (args *LightsailArguments) Validate() error

Validate implements river.Validator.

Jump to

Keyboard shortcuts

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