Help us shape the future of Go! Take the 2026 Go Developer Survey

common

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Nov 25, 2024 License: GPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AwsAccessKeyId     = "AWS_ACCESS_KEY_ID"
	AwsAccessSecretKey = "AWS_SECRET_ACCESS_KEY" //nolint:gosec
	AwsDefaultRegion   = "AWS_DEFAULT_REGION"
)

Variables

This section is empty.

Functions

func CreateSession

func CreateSession(credentialsfile, profile, region string) (sess *session.Session, err error)

CreateSession returns a standard session with the AWS CLI environment

This looks into two different config files, `~/.aws/credentials` for a secret to the specified profile, and `~/.aws/config` for the region name detection.

These are the standard config files, used by AWS CLI and other SDKs.

Also see https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-envvars.html

func CreateTestSession

func CreateTestSession(region string) (sess *session.Session)

func DetectRegionFromConfig

func DetectRegionFromConfig(filename string) (region string)

Types

This section is empty.

Jump to

Keyboard shortcuts

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