session

package
v3.29.0 Latest Latest
Warning

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

Go to latest
Published: Sep 21, 2020 License: MIT Imports: 4 Imported by: 8

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FieldSpecs added in v3.9.0

func FieldSpecs() docs.FieldSpecs

FieldSpecs returns documentation specs for AWS session fields.

Types

type Config

type Config struct {
	Credentials CredentialsConfig `json:"credentials" yaml:"credentials"`
	Endpoint    string            `json:"endpoint" yaml:"endpoint"`
	Region      string            `json:"region" yaml:"region"`
}

Config contains configuration fields for an AWS session. This config is common across any AWS components.

func NewConfig

func NewConfig() Config

NewConfig returns a Config with default values.

func (Config) GetSession

func (c Config) GetSession(opts ...func(*aws.Config)) (*session.Session, error)

GetSession attempts to create an AWS session based on Config.

type CredentialsConfig

type CredentialsConfig struct {
	Profile    string `json:"profile" yaml:"profile"`
	ID         string `json:"id" yaml:"id"`
	Secret     string `json:"secret" yaml:"secret"`
	Token      string `json:"token" yaml:"token"`
	Role       string `json:"role" yaml:"role"`
	ExternalID string `json:"role_external_id" yaml:"role_external_id"`
}

CredentialsConfig contains configuration params for AWS credentials.

Jump to

Keyboard shortcuts

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