aws

package
v0.0.0-...-dbdff16 Latest Latest
Warning

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

Go to latest
Published: Dec 18, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SharedCredentialsFileFromSecret

func SharedCredentialsFileFromSecret(secret *corev1.Secret) (string, error)

SharedCredentialsFileFromSecret returns a location (path) to the shared credentials file that was created using the provided secret.

Consumers can configure the aws Session using that file to use the credentials as follows:

sharedCredentialsFile, err := SharedCredentialsFileFromSecret(secret)
if err != nil {
	// handle error
}

options := session.Options{
	SharedConfigState: session.SharedConfigEnable,
	SharedConfigFiles: []string{sharedCredentialsFile},
}
sess := session.Must(session.NewSessionWithOptions(options))

Types

This section is empty.

Jump to

Keyboard shortcuts

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